aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--actionmailer/CHANGELOG2
-rw-r--r--actionmailer/README60
-rw-r--r--actionmailer/Rakefile4
-rw-r--r--actionmailer/actionmailer.gemspec3
-rw-r--r--actionmailer/lib/action_mailer.rb8
-rw-r--r--actionmailer/lib/action_mailer/base.rb795
-rw-r--r--actionmailer/lib/action_mailer/collector.rb36
-rw-r--r--actionmailer/lib/action_mailer/delivery_method.rb56
-rw-r--r--actionmailer/lib/action_mailer/delivery_method/file.rb21
-rw-r--r--actionmailer/lib/action_mailer/delivery_method/sendmail.rb22
-rw-r--r--actionmailer/lib/action_mailer/delivery_method/smtp.rb30
-rw-r--r--actionmailer/lib/action_mailer/delivery_method/test.rb12
-rw-r--r--actionmailer/lib/action_mailer/delivery_methods.rb90
-rw-r--r--actionmailer/lib/action_mailer/deprecated_api.rb139
-rw-r--r--actionmailer/lib/action_mailer/deprecated_body.rb46
-rw-r--r--actionmailer/lib/action_mailer/mail_helper.rb9
-rw-r--r--actionmailer/lib/action_mailer/old_api.rb248
-rw-r--r--actionmailer/lib/action_mailer/railtie.rb17
-rw-r--r--actionmailer/lib/action_mailer/test_case.rb2
-rw-r--r--actionmailer/lib/action_mailer/test_helper.rb1
-rw-r--r--actionmailer/lib/action_mailer/tmail_compat.rb12
-rwxr-xr-xactionmailer/lib/action_mailer/vendor/text-format-0.6.3/text/format.rb1467
-rw-r--r--actionmailer/lib/action_mailer/vendor/text_format.rb10
-rw-r--r--actionmailer/test/abstract_unit.rb25
-rw-r--r--actionmailer/test/base_test.rb488
-rw-r--r--actionmailer/test/delivery_method_test.rb101
-rw-r--r--actionmailer/test/delivery_methods_test.rb170
-rw-r--r--actionmailer/test/fixtures/another.path/base_mailer/welcome.erb1
-rw-r--r--actionmailer/test/fixtures/base_mailer/attachment_with_content.erb1
-rw-r--r--actionmailer/test/fixtures/base_mailer/explicit_multipart_templates.html.erb1
-rw-r--r--actionmailer/test/fixtures/base_mailer/explicit_multipart_templates.text.erb1
-rw-r--r--actionmailer/test/fixtures/base_mailer/html_only.html.erb1
-rw-r--r--actionmailer/test/fixtures/base_mailer/implicit_multipart.html.erb1
-rw-r--r--actionmailer/test/fixtures/base_mailer/implicit_multipart.text.erb1
-rw-r--r--actionmailer/test/fixtures/base_mailer/implicit_with_locale.en.html.erb1
-rw-r--r--actionmailer/test/fixtures/base_mailer/implicit_with_locale.html.erb1
-rw-r--r--actionmailer/test/fixtures/base_mailer/implicit_with_locale.pl.text.erb1
-rw-r--r--actionmailer/test/fixtures/base_mailer/implicit_with_locale.text.erb1
-rw-r--r--actionmailer/test/fixtures/base_mailer/plain_text_only.text.erb1
-rw-r--r--actionmailer/test/fixtures/base_mailer/welcome.erb1
-rw-r--r--actionmailer/test/fixtures/helper_mailer/use_example_helper.erb1
-rw-r--r--actionmailer/test/fixtures/helper_mailer/use_helper.erb1
-rw-r--r--actionmailer/test/fixtures/helper_mailer/use_helper_method.erb1
-rw-r--r--actionmailer/test/fixtures/helper_mailer/use_mail_helper.erb5
-rw-r--r--actionmailer/test/fixtures/helpers/example_helper.rb5
-rw-r--r--actionmailer/test/fixtures/nested_layout_mailer/signup.html.erb1
-rw-r--r--actionmailer/test/fixtures/test_mailer/body_ivar.erb2
-rw-r--r--actionmailer/test/fixtures/test_mailer/multipart_alternative.html.erb1
-rw-r--r--actionmailer/test/fixtures/test_mailer/multipart_alternative.plain.erb1
-rw-r--r--actionmailer/test/mail_helper_test.rb98
-rw-r--r--actionmailer/test/mail_test.rb24
-rw-r--r--actionmailer/test/old_base/adv_attr_test.rb (renamed from actionmailer/test/adv_attr_test.rb)0
-rw-r--r--actionmailer/test/old_base/asset_host_test.rb (renamed from actionmailer/test/asset_host_test.rb)14
-rw-r--r--actionmailer/test/old_base/mail_layout_test.rb (renamed from actionmailer/test/mail_layout_test.rb)51
-rw-r--r--actionmailer/test/old_base/mail_render_test.rb (renamed from actionmailer/test/mail_render_test.rb)122
-rw-r--r--actionmailer/test/old_base/mail_service_test.rb (renamed from actionmailer/test/mail_service_test.rb)292
-rw-r--r--actionmailer/test/old_base/tmail_compat_test.rb (renamed from actionmailer/test/tmail_compat_test.rb)16
-rw-r--r--actionmailer/test/old_base/url_test.rb (renamed from actionmailer/test/url_test.rb)8
-rw-r--r--actionmailer/test/subscriber_test.rb20
-rw-r--r--actionmailer/test/test_helper_test.rb26
-rw-r--r--actionpack/lib/abstract_controller.rb1
-rw-r--r--actionpack/lib/abstract_controller/collector.rb30
-rw-r--r--actionpack/lib/abstract_controller/layouts.rb3
-rw-r--r--actionpack/lib/abstract_controller/rendering.rb4
-rw-r--r--actionpack/lib/action_controller/base.rb2
-rw-r--r--actionpack/lib/action_controller/deprecated.rb1
-rw-r--r--actionpack/lib/action_controller/metal/helpers.rb76
-rw-r--r--actionpack/lib/action_controller/metal/mime_responds.rb29
-rw-r--r--actionpack/lib/action_controller/metal/rendering.rb4
-rw-r--r--actionpack/lib/action_controller/railtie.rb28
-rw-r--r--actionpack/lib/action_dispatch/middleware/callbacks.rb2
-rw-r--r--actionpack/lib/action_dispatch/middleware/stack.rb14
-rw-r--r--actionpack/lib/action_dispatch/railtie.rb15
-rw-r--r--actionpack/lib/action_dispatch/routing/mapper.rb5
-rw-r--r--actionpack/lib/action_dispatch/routing/route_set.rb28
-rw-r--r--actionpack/lib/action_view/base.rb6
-rw-r--r--actionpack/lib/action_view/helpers.rb8
-rw-r--r--actionpack/lib/action_view/helpers/ajax_helper.rb735
-rw-r--r--actionpack/lib/action_view/helpers/form_helper.rb36
-rw-r--r--actionpack/lib/action_view/helpers/form_tag_helper.rb20
-rw-r--r--actionpack/lib/action_view/helpers/javascript_helper.rb44
-rw-r--r--actionpack/lib/action_view/helpers/prototype_helper.rb450
-rw-r--r--actionpack/lib/action_view/helpers/translation_helper.rb8
-rw-r--r--actionpack/lib/action_view/helpers/url_helper.rb54
-rw-r--r--actionpack/lib/action_view/railtie.rb2
-rw-r--r--actionpack/lib/action_view/template.rb4
-rw-r--r--actionpack/lib/action_view/template/resolver.rb13
-rw-r--r--actionpack/test/abstract/collector_test.rb57
-rw-r--r--actionpack/test/abstract/helper_test.rb2
-rw-r--r--actionpack/test/abstract/layouts_test.rb17
-rw-r--r--actionpack/test/controller/helper_test.rb20
-rw-r--r--actionpack/test/dispatch/middleware_stack_test.rb6
-rw-r--r--actionpack/test/dispatch/routing_test.rb21
-rw-r--r--actionpack/test/fixtures/helpers/fun/games_helper.rb6
-rw-r--r--actionpack/test/fixtures/helpers/fun/pdf_helper.rb6
-rw-r--r--actionpack/test/fixtures/test/translation.erb1
-rw-r--r--actionpack/test/template/ajax_helper_test.rb452
-rw-r--r--actionpack/test/template/ajax_test.rb114
-rw-r--r--actionpack/test/template/form_helper_test.rb8
-rw-r--r--actionpack/test/template/form_tag_helper_test.rb12
-rw-r--r--actionpack/test/template/prototype_helper_test.rb193
-rw-r--r--actionpack/test/template/translation_helper_test.rb10
-rw-r--r--actionpack/test/template/url_helper_test.rb28
-rw-r--r--activerecord/CHANGELOG2
-rw-r--r--activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb6
-rw-r--r--activerecord/lib/active_record/connection_adapters/sqlite_adapter.rb6
-rw-r--r--activerecord/lib/active_record/railtie.rb30
-rw-r--r--activerecord/lib/active_record/railties/databases.rake2
-rw-r--r--activerecord/lib/active_record/relation/query_methods.rb16
-rw-r--r--activerecord/test/cases/calculations_test.rb3
-rw-r--r--activerecord/test/cases/datatype_test_postgresql.rb39
-rw-r--r--activerecord/test/cases/query_cache_test.rb6
-rw-r--r--activerecord/test/schema/postgresql_specific_schema.rb9
-rw-r--r--activeresource/lib/active_resource/railtie.rb8
-rw-r--r--activeresource/lib/active_resource/validations.rb6
-rw-r--r--activeresource/test/cases/base_errors_test.rb13
-rw-r--r--activesupport/CHANGELOG10
-rw-r--r--activesupport/Rakefile100
-rw-r--r--activesupport/activesupport.gemspec3
-rw-r--r--activesupport/lib/active_support.rb2
-rw-r--r--activesupport/lib/active_support/core_ext/array.rb1
-rw-r--r--activesupport/lib/active_support/core_ext/array/conversions.rb13
-rw-r--r--activesupport/lib/active_support/core_ext/array/uniq_by.rb17
-rw-r--r--activesupport/lib/active_support/core_ext/class.rb1
-rw-r--r--activesupport/lib/active_support/core_ext/class/removal.rb57
-rw-r--r--activesupport/lib/active_support/core_ext/hash/deep_merge.rb13
-rw-r--r--activesupport/lib/active_support/core_ext/hash/keys.rb15
-rw-r--r--activesupport/lib/active_support/core_ext/object.rb1
-rw-r--r--activesupport/lib/active_support/core_ext/object/extending.rb63
-rw-r--r--activesupport/lib/active_support/core_ext/time/calculations.rb2
-rw-r--r--activesupport/lib/active_support/ordered_hash.rb25
-rw-r--r--activesupport/lib/active_support/railtie.rb64
-rw-r--r--activesupport/lib/active_support/values/time_zone.rb6
-rw-r--r--activesupport/lib/active_support/vendor.rb19
-rw-r--r--activesupport/lib/active_support/vendor/builder-2.1.2/lib/blankslate.rb113
-rw-r--r--activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder.rb13
-rw-r--r--activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/blankslate.rb20
-rw-r--r--activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/css.rb250
-rw-r--r--activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/xchar.rb115
-rw-r--r--activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/xmlbase.rb139
-rw-r--r--activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/xmlevents.rb63
-rw-r--r--activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/xmlmarkup.rb328
-rw-r--r--activesupport/lib/active_support/vendor/memcache-client-1.7.5/lib/memcache.rb1133
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo.rb33
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/data_timezone.rb47
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/data_timezone_info.rb228
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Algiers.rb55
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Cairo.rb219
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Casablanca.rb42
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Harare.rb18
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Johannesburg.rb25
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Monrovia.rb22
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Nairobi.rb23
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Argentina/Buenos_Aires.rb84
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Argentina/San_Juan.rb86
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Bogota.rb23
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Caracas.rb23
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Chicago.rb283
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Chihuahua.rb136
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Denver.rb204
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Godthab.rb161
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Guatemala.rb27
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Halifax.rb274
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Indiana/Indianapolis.rb149
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Juneau.rb194
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/La_Paz.rb22
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Lima.rb35
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Los_Angeles.rb232
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Mazatlan.rb139
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Mexico_City.rb144
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Monterrey.rb131
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/New_York.rb282
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Phoenix.rb30
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Regina.rb74
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Santiago.rb205
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Sao_Paulo.rb171
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/St_Johns.rb288
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Tijuana.rb196
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Almaty.rb67
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Baghdad.rb73
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Baku.rb161
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Bangkok.rb20
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Chongqing.rb33
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Colombo.rb30
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Dhaka.rb29
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Hong_Kong.rb87
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Irkutsk.rb165
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Jakarta.rb30
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Jerusalem.rb163
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kabul.rb20
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kamchatka.rb163
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Karachi.rb114
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kathmandu.rb20
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kolkata.rb25
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Krasnoyarsk.rb163
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kuala_Lumpur.rb31
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kuwait.rb18
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Magadan.rb163
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Muscat.rb18
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Novosibirsk.rb164
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Rangoon.rb24
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Riyadh.rb18
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Seoul.rb34
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Shanghai.rb35
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Singapore.rb33
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Taipei.rb59
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Tashkent.rb47
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Tbilisi.rb78
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Tehran.rb121
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Tokyo.rb30
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Ulaanbaatar.rb65
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Urumqi.rb33
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Vladivostok.rb164
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Yakutsk.rb163
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Yekaterinburg.rb165
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Yerevan.rb165
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Atlantic/Azores.rb270
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Atlantic/Cape_Verde.rb23
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Atlantic/South_Georgia.rb18
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Adelaide.rb187
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Brisbane.rb35
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Darwin.rb29
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Hobart.rb193
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Melbourne.rb185
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Perth.rb37
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Sydney.rb185
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Etc/UTC.rb16
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Amsterdam.rb228
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Athens.rb185
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Belgrade.rb163
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Berlin.rb188
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Bratislava.rb13
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Brussels.rb232
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Bucharest.rb181
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Budapest.rb197
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Copenhagen.rb179
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Dublin.rb276
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Helsinki.rb163
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Istanbul.rb218
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Kiev.rb168
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Lisbon.rb268
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Ljubljana.rb13
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/London.rb288
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Madrid.rb211
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Minsk.rb170
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Moscow.rb181
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Paris.rb232
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Prague.rb187
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Riga.rb176
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Rome.rb215
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Sarajevo.rb13
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Skopje.rb13
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Sofia.rb173
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Stockholm.rb165
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Tallinn.rb172
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Vienna.rb183
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Vilnius.rb170
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Warsaw.rb212
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Zagreb.rb13
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Auckland.rb202
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Fiji.rb23
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Guam.rb22
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Honolulu.rb28
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Majuro.rb20
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Midway.rb25
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Noumea.rb25
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Pago_Pago.rb26
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Port_Moresby.rb20
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Tongatapu.rb27
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/info_timezone.rb52
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/linked_timezone.rb51
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/linked_timezone_info.rb44
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/offset_rationals.rb98
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/ruby_core_support.rb56
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/time_or_datetime.rb292
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone.rb508
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone_definition.rb56
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone_info.rb40
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone_offset_info.rb94
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone_period.rb198
-rw-r--r--activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone_transition_info.rb129
-rw-r--r--activesupport/test/core_ext/array_ext_test.rb40
-rw-r--r--activesupport/test/core_ext/class_test.rb47
-rw-r--r--activesupport/test/core_ext/object_and_class_ext_test.rb93
-rw-r--r--activesupport/test/core_ext/time_ext_test.rb4
-rw-r--r--activesupport/test/core_ext/time_with_zone_test.rb5
-rw-r--r--activesupport/test/ordered_hash_test.rb24
-rw-r--r--railties/lib/generators/erb/mailer/mailer_generator.rb2
-rw-r--r--railties/lib/generators/erb/mailer/templates/view.erb3
-rw-r--r--railties/lib/generators/erb/mailer/templates/view.text.erb3
-rwxr-xr-xrailties/lib/generators/rails/app/templates/Rakefile2
-rw-r--r--railties/lib/generators/rails/app/templates/config/boot.rb6
-rw-r--r--railties/lib/generators/rails/app/templates/public/javascripts/jquery-1.4.1.min.js152
-rw-r--r--railties/lib/generators/rails/app/templates/public/javascripts/jquery.rails.js239
-rw-r--r--railties/lib/generators/rails/app/templates/public/javascripts/prototype.rails.js324
-rwxr-xr-xrailties/lib/generators/rails/app/templates/script/console.tt2
-rwxr-xr-xrailties/lib/generators/rails/app/templates/script/dbconsole.tt2
-rw-r--r--railties/lib/generators/rails/mailer/templates/mailer.rb18
-rw-r--r--railties/lib/generators/rails/metal/templates/metal.rb2
-rw-r--r--railties/lib/generators/rails/plugin/plugin_generator.rb2
-rw-r--r--railties/lib/generators/rails/plugin/templates/lib/tasks/%file_name%_tasks.rake.tt (renamed from railties/lib/generators/rails/plugin/templates/tasks/%file_name%_tasks.rake.tt)0
-rw-r--r--railties/lib/generators/rails/resource/resource_generator.rb4
-rw-r--r--railties/lib/generators/rails/scaffold_controller/scaffold_controller_generator.rb6
-rw-r--r--railties/lib/generators/test_unit/mailer/templates/fixture2
-rw-r--r--railties/lib/generators/test_unit/mailer/templates/functional_test.rb8
-rw-r--r--railties/lib/rails.rb10
-rw-r--r--railties/lib/rails/all.rb2
-rw-r--r--railties/lib/rails/application.rb182
-rw-r--r--railties/lib/rails/application/bootstrap.rb85
-rw-r--r--railties/lib/rails/application/configurable.rb19
-rw-r--r--railties/lib/rails/application/configuration.rb84
-rw-r--r--railties/lib/rails/application/finisher.rb49
-rw-r--r--railties/lib/rails/application/metal_loader.rb50
-rw-r--r--railties/lib/rails/application/railties.rb31
-rw-r--r--railties/lib/rails/application/routes_reloader.rb46
-rw-r--r--railties/lib/rails/bootstrap.rb161
-rw-r--r--railties/lib/rails/commands/console.rb8
-rw-r--r--railties/lib/rails/configuration.rb399
-rw-r--r--railties/lib/rails/console/app.rb (renamed from railties/lib/rails/console_app.rb)11
-rw-r--r--railties/lib/rails/console/helpers.rb (renamed from railties/lib/rails/console_with_helpers.rb)0
-rw-r--r--railties/lib/rails/console/sandbox.rb (renamed from railties/lib/rails/console_sandbox.rb)0
-rw-r--r--railties/lib/rails/engine.rb130
-rw-r--r--railties/lib/rails/engine/configurable.rb25
-rw-r--r--railties/lib/rails/engine/configuration.rb49
-rw-r--r--railties/lib/rails/generators.rb21
-rw-r--r--railties/lib/rails/generators/named_base.rb79
-rw-r--r--railties/lib/rails/generators/resource_helpers.rb43
-rw-r--r--railties/lib/rails/initializable.rb26
-rw-r--r--railties/lib/rails/paths.rb44
-rw-r--r--railties/lib/rails/plugin.rb65
-rw-r--r--railties/lib/rails/rack.rb1
-rw-r--r--railties/lib/rails/rack/logger.rb18
-rw-r--r--railties/lib/rails/rack/metal.rb26
-rw-r--r--railties/lib/rails/railtie.rb83
-rw-r--r--railties/lib/rails/railtie/configurable.rb23
-rw-r--r--railties/lib/rails/railtie/configuration.rb9
-rw-r--r--railties/lib/rails/tasks.rb1
-rw-r--r--railties/lib/rails/tasks/documentation.rake54
-rw-r--r--railties/lib/rails/tasks/middleware.rake2
-rw-r--r--railties/lib/rails/tasks/routes.rake1
-rw-r--r--railties/lib/rails/test_unit/railtie.rb17
-rw-r--r--railties/test/application/configuration_test.rb64
-rw-r--r--railties/test/application/console_test.rb4
-rw-r--r--railties/test/application/generators_test.rb25
-rw-r--r--railties/test/application/initializer_test.rb185
-rw-r--r--railties/test/application/initializers/boot_test.rb (renamed from railties/test/initializer/boot_test.rb)2
-rw-r--r--railties/test/application/initializers/check_ruby_version_test.rb (renamed from railties/test/initializer/check_ruby_version_test.rb)2
-rw-r--r--railties/test/application/initializers/frameworks_test.rb86
-rw-r--r--railties/test/application/initializers/i18n_test.rb55
-rw-r--r--railties/test/application/initializers/initializers_test.rb55
-rw-r--r--railties/test/application/initializers/load_path_test.rb74
-rw-r--r--railties/test/application/initializers/notifications_test.rb (renamed from railties/test/application/notifications_test.rb)27
-rw-r--r--railties/test/application/middleware_test.rb7
-rw-r--r--railties/test/application/paths_test.rb (renamed from railties/test/initializer/path_test.rb)28
-rw-r--r--railties/test/application/rackup_test.rb (renamed from railties/test/application/load_test.rb)2
-rw-r--r--railties/test/application/routing_test.rb78
-rw-r--r--railties/test/fixtures/eager/zoo.rb3
-rw-r--r--railties/test/fixtures/eager/zoo/reptile_house.rb2
-rw-r--r--railties/test/fixtures/environment_with_constant.rb1
-rw-r--r--railties/test/fixtures/plugins/alternate/a/generators/a_generator/a_generator.rb4
-rw-r--r--railties/test/fixtures/plugins/alternate/a/lib/.gitignore0
-rw-r--r--railties/test/fixtures/plugins/default/acts/acts_as_chunky_bacon/lib/.gitignore0
-rw-r--r--railties/test/fixtures/plugins/default/empty/.gitignore0
-rw-r--r--railties/test/fixtures/plugins/default/gemlike/init.rb1
-rw-r--r--railties/test/fixtures/plugins/default/gemlike/lib/gemlike.rb2
-rw-r--r--railties/test/fixtures/plugins/default/gemlike/rails/init.rb7
-rw-r--r--railties/test/fixtures/plugins/default/plugin_with_no_lib_dir/init.rb0
-rw-r--r--railties/test/fixtures/plugins/default/stubby/about.yml2
-rw-r--r--railties/test/fixtures/plugins/default/stubby/init.rb7
-rw-r--r--railties/test/fixtures/plugins/default/stubby/lib/stubby_mixin.rb2
-rw-r--r--railties/test/fixtures/plugins/engines/engine/app/controllers/engine_controller.rb2
-rw-r--r--railties/test/fixtures/plugins/engines/engine/app/metal/engine_metal.rb10
-rw-r--r--railties/test/fixtures/plugins/engines/engine/app/models/engine_model.rb2
-rw-r--r--railties/test/fixtures/plugins/engines/engine/config/locales/en.yml2
-rw-r--r--railties/test/fixtures/plugins/engines/engine/config/routes.rb3
-rw-r--r--railties/test/fixtures/plugins/engines/engine/init.rb3
-rw-r--r--railties/test/generators/generators_test_helper.rb2
-rw-r--r--railties/test/generators/mailer_generator_test.rb39
-rw-r--r--railties/test/generators/named_base_test.rb70
-rw-r--r--railties/test/generators/plugin_generator_test.rb2
-rw-r--r--railties/test/generators_test.rb1
-rw-r--r--railties/test/initializable_test.rb28
-rw-r--r--railties/test/initializer/initialize_i18n_test.rb55
-rw-r--r--railties/test/isolation/abstract_unit.rb21
-rw-r--r--railties/test/mocks/routes.rb6
-rw-r--r--railties/test/paths_test.rb27
-rw-r--r--railties/test/plugins/configuration_test.rb45
-rw-r--r--railties/test/plugins/framework_extension_test.rb68
-rw-r--r--railties/test/plugins/vendored_test.rb201
-rw-r--r--railties/test/railties/engine_test.rb32
-rw-r--r--railties/test/railties/plugin_ordering_test.rb72
-rw-r--r--railties/test/railties/plugin_test.rb115
-rw-r--r--railties/test/railties/railtie_test.rb132
-rw-r--r--railties/test/railties/shared_tests.rb315
-rw-r--r--railties/test/vendor/gems/dummy-gem-a-0.4.0/.specification28
-rw-r--r--railties/test/vendor/gems/dummy-gem-a-0.4.0/lib/dummy-gem-a.rb1
-rw-r--r--railties/test/vendor/gems/dummy-gem-b-0.4.0/.specification28
-rw-r--r--railties/test/vendor/gems/dummy-gem-b-0.4.0/lib/dummy-gem-b.rb1
-rw-r--r--railties/test/vendor/gems/dummy-gem-b-0.6.0/.specification28
-rw-r--r--railties/test/vendor/gems/dummy-gem-b-0.6.0/lib/dummy-gem-b.rb1
-rw-r--r--railties/test/vendor/gems/dummy-gem-c-0.4.0/.specification28
-rw-r--r--railties/test/vendor/gems/dummy-gem-c-0.4.0/lib/dummy-gem-c.rb1
-rw-r--r--railties/test/vendor/gems/dummy-gem-c-0.6.0/.specification28
-rw-r--r--railties/test/vendor/gems/dummy-gem-c-0.6.0/lib/dummy-gem-c.rb1
-rw-r--r--railties/test/vendor/gems/dummy-gem-d-1.0.0/lib/dummy-gem-d.rb1
-rw-r--r--railties/test/vendor/gems/dummy-gem-e-1.0.0/.specification28
-rw-r--r--railties/test/vendor/gems/dummy-gem-e-1.0.0/lib/dummy-gem-e.rb1
-rw-r--r--railties/test/vendor/gems/dummy-gem-f-1.0.0/.specification39
-rw-r--r--railties/test/vendor/gems/dummy-gem-f-1.0.0/lib/dummy-gem-f.rb1
-rw-r--r--railties/test/vendor/gems/dummy-gem-g-1.0.0/.specification39
-rw-r--r--railties/test/vendor/gems/dummy-gem-g-1.0.0/lib/dummy-gem-g.rb1
-rw-r--r--railties/test/vendor/gems/dummy-gem-h-1.0.0/.specification29
-rw-r--r--railties/test/vendor/gems/dummy-gem-h-1.0.0/lib/dummy-gem-h.rb1
-rw-r--r--railties/test/vendor/gems/dummy-gem-i-1.0.0/.specification41
-rw-r--r--railties/test/vendor/gems/dummy-gem-i-1.0.0/ext/dummy-gem-i/Makefile0
-rw-r--r--railties/test/vendor/gems/dummy-gem-i-1.0.0/lib/dummy-gem-i.rb1
-rw-r--r--railties/test/vendor/gems/dummy-gem-j-1.0.0/.specification41
-rw-r--r--railties/test/vendor/gems/dummy-gem-j-1.0.0/lib/dummy-gem-j.rb1
-rw-r--r--railties/test/vendor/gems/dummy-gem-k-1.0.0/.specification49
-rw-r--r--railties/test/vendor/gems/dummy-gem-k-1.0.0/lib/dummy-gem-k.rb1
420 files changed, 6729 insertions, 24351 deletions
diff --git a/actionmailer/CHANGELOG b/actionmailer/CHANGELOG
index 785bf98c55..0018a2ed5d 100644
--- a/actionmailer/CHANGELOG
+++ b/actionmailer/CHANGELOG
@@ -1,5 +1,7 @@
*Rails 3.0 (pending)*
+* Whole new API added with tests. See base.rb for full details. Old API is deprecated.
+
* The Mail::Message class has helped methods for all the field types that return 'common' defaults for the common use case, so to get the subject, mail.subject will give you a string, mail.date will give you a DateTime object, mail.from will give you an array of address specs (mikel@test.lindsaar.net) etc. If you want to access the field object itself, call mail[:field_name] which will return the field object you want, which you can then chain, like mail[:from].formatted
* Mail#content_type now returns the content_type field as a string. If you want the mime type of a mail, then you call Mail#mime_type (eg, text/plain), if you want the parameters of the content type field, you call Mail#content_type_parameters which gives you a hash, eg {'format' => 'flowed', 'charset' => 'utf-8'}
diff --git a/actionmailer/README b/actionmailer/README
index 0e16ea6ec6..e0e2ee436a 100644
--- a/actionmailer/README
+++ b/actionmailer/README
@@ -5,51 +5,72 @@ are used to consolidate code for sending out forgotten passwords, welcome
wishes on signup, invoices for billing, and any other use case that requires
a written notification to either a person or another system.
+Action Mailer is in essence a wrapper around Action Controller and the
+Mail gem. It provides a way to make emails using templates in the same
+way that Action Controller renders views using templates.
+
Additionally, an Action Mailer class can be used to process incoming email,
such as allowing a weblog to accept new posts from an email (which could even
have been sent from a phone).
== Sending emails
-The framework works by setting up all the email details, except the body,
-in methods on the service layer. Subject, recipients, sender, and timestamp
-are all set up this way. An example of such a method:
+The framework works by initializing any instance variables you want to be
+available in the email template, followed by a call to +mail+ to deliver
+the email.
+
+This can be as simple as:
- def signed_up(recipient)
- recipients recipient
- subject "[Signed up] Welcome #{recipient}"
- from "system@loudthinking.com"
- body :recipient => recipient
+ class Notifier < ActionMailer::Base
+ delivers_from 'system@loudthinking.com'
+
+ def welcome(recipient)
+ @recipient = recipient
+ mail(:to => recipient,
+ :subject => "[Signed up] Welcome #{recipient}")
+ end
end
The body of the email is created by using an Action View template (regular
-ERb) that has the content of the body hash parameter available as instance variables.
+ERb) that has the instance variables that are declared in the mailer action.
+
So the corresponding body template for the method above could look like this:
Hello there,
Mr. <%= @recipient %>
+
+ Thank you for signing up!
And if the recipient was given as "david@loudthinking.com", the email
generated would look like this:
- Date: Sun, 12 Dec 2004 00:00:00 +0100
+ Date: Mon, 25 Jan 2010 22:48:09 +1100
From: system@loudthinking.com
To: david@loudthinking.com
+ Message-ID: <4b5d84f9dd6a5_7380800b81ac29578@void.loudthinking.com.mail>
Subject: [Signed up] Welcome david@loudthinking.com
+ Mime-Version: 1.0
+ Content-Type: text/plain;
+ charset="US-ASCII";
+ Content-Transfer-Encoding: 7bit
Hello there,
Mr. david@loudthinking.com
-You never actually call the instance methods like signed_up directly. Instead,
-you call class methods like deliver_* and create_* that are automatically
-created for each instance method. So if the signed_up method sat on
-ApplicationMailer, it would look like this:
+In previous version of rails you would call <tt>create_method_name</tt> and
+<tt>deliver_method_name</tt>. Rails 3.0 has a much simpler interface, you
+simply call the method and optionally call +deliver+ on the return value.
- ApplicationMailer.create_signed_up("david@loudthinking.com") # => tmail object for testing
- ApplicationMailer.deliver_signed_up("david@loudthinking.com") # sends the email
- ApplicationMailer.new.signed_up("david@loudthinking.com") # won't work!
+Calling the method returns a Mail Message object:
+
+ message = Notifier.welcome #=> Returns a Mail::Message object
+ message.deliver #=> delivers the email
+
+Or you can just chain the methods together like:
+
+ Notifier.welcome.deliver # Creates the email and sends it immediately
== Receiving emails
@@ -103,16 +124,13 @@ The Base class has the full list of configuration options. Here's an example:
Action Mailer requires that the Action Pack is either available to be required immediately
or is accessible as a GEM.
+Additionally, Action Mailer requires the Mail gem, http://github.com/mikel/mail
== Bundled software
-* tmail 0.10.8 by Minero Aoki released under LGPL
- Read more on http://i.loveruby.net/en/prog/tmail.html
-
* Text::Format 0.63 by Austin Ziegler released under OpenSource
Read more on http://www.halostatue.ca/ruby/Text__Format.html
-
== Download
The latest version of Action Mailer can be found at
diff --git a/actionmailer/Rakefile b/actionmailer/Rakefile
index 6c19371514..2619d9359e 100644
--- a/actionmailer/Rakefile
+++ b/actionmailer/Rakefile
@@ -22,14 +22,14 @@ task :default => [ :test ]
# Run the unit tests
Rake::TestTask.new { |t|
t.libs << "test"
- t.pattern = 'test/*_test.rb'
+ t.pattern = 'test/**/*_test.rb'
t.warning = true
}
namespace :test do
task :isolated do
ruby = File.join(*RbConfig::CONFIG.values_at('bindir', 'RUBY_INSTALL_NAME'))
- Dir.glob("test/*_test.rb").all? do |file|
+ Dir.glob("test/**/*_test.rb").all? do |file|
system(ruby, '-Ilib:test', file)
end or raise "Failures"
end
diff --git a/actionmailer/actionmailer.gemspec b/actionmailer/actionmailer.gemspec
index 96549bf29c..abbb542293 100644
--- a/actionmailer/actionmailer.gemspec
+++ b/actionmailer/actionmailer.gemspec
@@ -11,7 +11,8 @@ Gem::Specification.new do |s|
s.homepage = "http://www.rubyonrails.org"
s.add_dependency('actionpack', '= 3.0.pre')
- s.add_dependency('mail', '~> 1.6.0')
+ s.add_dependency('mail', '~> 2.1.2')
+ s.add_dependency('text-format', '~> 1.0.0')
s.files = Dir['CHANGELOG', 'README', 'MIT-LICENSE', 'lib/**/*']
s.has_rdoc = true
diff --git a/actionmailer/lib/action_mailer.rb b/actionmailer/lib/action_mailer.rb
index 55ddbb24f4..17f63aca25 100644
--- a/actionmailer/lib/action_mailer.rb
+++ b/actionmailer/lib/action_mailer.rb
@@ -31,10 +31,12 @@ module ActionMailer
extend ::ActiveSupport::Autoload
autoload :AdvAttrAccessor
+ autoload :Collector
autoload :Base
- autoload :DeliveryMethod
- autoload :DeprecatedBody
+ autoload :DeliveryMethods
+ autoload :DeprecatedApi
autoload :MailHelper
+ autoload :OldApi
autoload :Quoting
autoload :TestCase
autoload :TestHelper
@@ -43,5 +45,5 @@ end
module Text
extend ActiveSupport::Autoload
- autoload :Format, 'action_mailer/vendor/text_format'
+ autoload :Format, 'text/format'
end
diff --git a/actionmailer/lib/action_mailer/base.rb b/actionmailer/lib/action_mailer/base.rb
index 356861b591..6246530bf0 100644
--- a/actionmailer/lib/action_mailer/base.rb
+++ b/actionmailer/lib/action_mailer/base.rb
@@ -1,6 +1,11 @@
require 'active_support/core_ext/class'
+require 'active_support/core_ext/object/blank'
+require 'active_support/core_ext/array/uniq_by'
+require 'active_support/core_ext/module/delegation'
+require 'active_support/core_ext/string/inflections'
require 'mail'
require 'action_mailer/tmail_compat'
+require 'action_mailer/collector'
module ActionMailer #:nodoc:
# Action Mailer allows you to send email from your application using a mailer model and views.
@@ -11,46 +16,76 @@ module ActionMailer #:nodoc:
#
# $ script/generate mailer Notifier
#
- # The generated model inherits from ActionMailer::Base. Emails are defined by creating methods within the model which are then
- # used to set variables to be used in the mail template, to change options on the mail, or
- # to add attachments.
+ # The generated model inherits from ActionMailer::Base. Emails are defined by creating methods
+ # within the model which are then used to set variables to be used in the mail template, to
+ # change options on the mail, or to add attachments.
#
# Examples:
#
# class Notifier < ActionMailer::Base
- # def signup_notification(recipient)
- # recipients recipient.email_address_with_name
- # bcc ["bcc@example.com", "Order Watcher <watcher@example.com>"]
- # from "system@example.com"
- # subject "New account information"
- # body :account => recipient
+ # default :from => 'no-reply@example.com',
+ # :return_path => 'system@example.com'
+ #
+ # def welcome(recipient)
+ # @account = recipient
+ # mail(:to => recipient.email_address_with_name,
+ # :bcc => ["bcc@example.com", "Order Watcher <watcher@example.com>"])
+ # end
# end
- # end
+ #
+ # Within the mailer method, you have access to the following methods:
+ #
+ # * <tt>attachments[]=</tt> - Allows you to add attachments to your email in an intuitive
+ # manner; <tt>attachments['filename.png'] = File.read('path/to/filename.png')</tt>
+ #
+ # * <tt>headers[]=</tt> - Allows you to specify non standard headers in your email such
+ # as <tt>headers['X-No-Spam'] = 'True'</tt>
+ #
+ # * <tt>headers(hash)</tt> - Allows you to specify multiple headers in your email such
+ # as <tt>headers({'X-No-Spam' => 'True', 'In-Reply-To' => '1234@message.id'})</tt>
+ #
+ # * <tt>mail</tt> - Allows you to specify your email to send.
+ #
+ # The hash passed to the mail method allows you to specify any header that a Mail::Message
+ # will accept (any valid Email header including optional fields). Obviously if you specify
+ # the same header in the headers method and then again in the mail method, the last one
+ # will over write the first, unless you are specifying a header field that can appear more
+ # than once per RFC, in which case, both will be inserted (X-value headers for example can
+ # appear multiple times.)
+ #
+ # The mail method, if not passed a block, will inspect your views and send all the views with
+ # the same name as the method, so the above action would send the +welcome.plain.erb+ view file
+ # as well as the +welcome.html.erb+ view file in a +multipart/alternative+ email.
+ #
+ # If you want to explicitly render only certain templates, pass a block:
+ #
+ # mail(:to => user.emai) do |format|
+ # format.text
+ # format.html
+ # end
#
- # Mailer methods have the following configuration methods available.
+ # The block syntax is useful if also need to specify information specific to a part:
#
- # * <tt>recipients</tt> - Takes one or more email addresses. These addresses are where your email will be delivered to. Sets the <tt>To:</tt> header.
- # * <tt>subject</tt> - The subject of your email. Sets the <tt>Subject:</tt> header.
- # * <tt>from</tt> - Who the email you are sending is from. Sets the <tt>From:</tt> header.
- # * <tt>cc</tt> - Takes one or more email addresses. These addresses will receive a carbon copy of your email. Sets the <tt>Cc:</tt> header.
- # * <tt>bcc</tt> - Takes one or more email addresses. These addresses will receive a blind carbon copy of your email. Sets the <tt>Bcc:</tt> header.
- # * <tt>reply_to</tt> - Takes one or more email addresses. These addresses will be listed as the default recipients when replying to your email. Sets the <tt>Reply-To:</tt> header.
- # * <tt>sent_on</tt> - The date on which the message was sent. If not set, the header will be set by the delivery agent.
- # * <tt>content_type</tt> - Specify the content type of the message. Defaults to <tt>text/plain</tt>.
- # * <tt>headers</tt> - Specify additional headers to be set for the message, e.g. <tt>headers 'X-Mail-Count' => 107370</tt>.
+ # mail(:to => user.emai) do |format|
+ # format.text(:content_transfer_encoding => "base64")
+ # format.html
+ # end
#
- # When a <tt>headers 'return-path'</tt> is specified, that value will be used as the 'envelope from'
- # address. Setting this is useful when you want delivery notifications sent to a different address than
- # the one in <tt>from</tt>.
+ # Or even to renderize a special view:
#
+ # mail(:to => user.emai) do |format|
+ # format.text
+ # format.html { render "some_other_template" }
+ # end
#
# = Mailer views
#
- # Like Action Controller, each mailer class has a corresponding view directory
- # in which each method of the class looks for a template with its name.
- # To define a template to be used with a mailing, create an <tt>.erb</tt> file with the same name as the method
- # in your mailer model. For example, in the mailer defined above, the template at
- # <tt>app/views/notifier/signup_notification.erb</tt> would be used to generate the email.
+ # Like Action Controller, each mailer class has a corresponding view directory in which each
+ # method of the class looks for a template with its name.
+ #
+ # To define a template to be used with a mailing, create an <tt>.erb</tt> file with the same
+ # name as the method in your mailer model. For example, in the mailer defined above, the template at
+ # <tt>app/views/notifier/signup_notification.text.erb</tt> would be used to generate the email.
#
# Variables defined in the model are accessible as instance variables in the view.
#
@@ -64,9 +99,9 @@ module ActionMailer #:nodoc:
# You got a new note!
# <%= truncate(@note.body, 25) %>
#
- # If you need to access the subject, from or the recipients in the view, you can do that through mailer object:
+ # If you need to access the subject, from or the recipients in the view, you can do that through message object:
#
- # You got a new note from <%= mailer.from %>!
+ # You got a new note from <%= message.from %>!
# <%= truncate(@note.body, 25) %>
#
#
@@ -106,54 +141,13 @@ module ActionMailer #:nodoc:
# Once a mailer action and template are defined, you can deliver your message or create it and save it
# for delivery later:
#
- # Notifier.deliver_signup_notification(david) # sends the email
- # mail = Notifier.create_signup_notification(david) # => a tmail object
- # Notifier.deliver(mail)
- #
- # You never instantiate your mailer class. Rather, your delivery instance
- # methods are automatically wrapped in class methods that start with the word
- # <tt>deliver_</tt> followed by the name of the mailer method that you would
- # like to deliver. The <tt>signup_notification</tt> method defined above is
- # delivered by invoking <tt>Notifier.deliver_signup_notification</tt>.
+ # Notifier.welcome(david).deliver # sends the email
+ # mail = Notifier.welcome(david) # => a Mail::Message object
+ # mail.deliver # sends the email
#
+ # You never instantiate your mailer class. Rather, you just call the method on the class itself.
#
- # = HTML email
- #
- # To send mail as HTML, make sure your view (the <tt>.erb</tt> file) generates HTML and
- # set the content type to html.
- #
- # class MyMailer < ActionMailer::Base
- # def signup_notification(recipient)
- # recipients recipient.email_address_with_name
- # subject "New account information"
- # from "system@example.com"
- # body :account => recipient
- # content_type "text/html"
- # end
- # end
- #
- #
- # = Multipart email
- #
- # You can explicitly specify multipart messages:
- #
- # class ApplicationMailer < ActionMailer::Base
- # def signup_notification(recipient)
- # recipients recipient.email_address_with_name
- # subject "New account information"
- # from "system@example.com"
- # content_type "multipart/alternative"
- # body :account => recipient
- #
- # part :content_type => "text/html",
- # :data => render_message("signup-as-html")
- #
- # part "text/plain" do |p|
- # p.body = render_message("signup-as-plain")
- # p.content_transfer_encoding = "base64"
- # end
- # end
- # end
+ # = Multipart Emails
#
# Multipart messages can also be used implicitly because Action Mailer will automatically
# detect and use multipart templates, where each template is named after the name of the action, followed
@@ -163,13 +157,12 @@ module ActionMailer #:nodoc:
# * signup_notification.text.plain.erb
# * signup_notification.text.html.erb
# * signup_notification.text.xml.builder
- # * signup_notification.text.x-yaml.erb
+ # * signup_notification.text.yaml.erb
#
- # Each would be rendered and added as a separate part to the message,
- # with the corresponding content type. The content type for the entire
- # message is automatically set to <tt>multipart/alternative</tt>, which indicates
- # that the email contains multiple different representations of the same email
- # body. The same body hash is passed to each template.
+ # Each would be rendered and added as a separate part to the message, with the corresponding content
+ # type. The content type for the entire message is automatically set to <tt>multipart/alternative</tt>,
+ # which indicates that the email contains multiple different representations of the same email
+ # body. The same instance variables defined in the action are passed to all email templates.
#
# Implicit template rendering is not performed if any attachments or parts have been added to the email.
# This means that you'll have to manually add each part to the email and set the content type of the email
@@ -177,32 +170,35 @@ module ActionMailer #:nodoc:
#
# = Attachments
#
- # Attachments can be added by using the +attachment+ method.
- #
- # Example:
+ # You can see above how to make a multipart HTML / Text email, to send attachments is just
+ # as easy:
#
# class ApplicationMailer < ActionMailer::Base
- # # attachments
- # def signup_notification(recipient)
- # recipients recipient.email_address_with_name
- # subject "New account information"
- # from "system@example.com"
- #
- # attachment :content_type => "image/jpeg",
- # :body => File.read("an-image.jpg")
- #
- # attachment "application/pdf" do |a|
- # a.body = generate_your_pdf_here()
- # end
+ # def welcome(recipient)
+ # attachments['free_book.pdf'] = { :data => File.read('path/to/file.pdf') }
+ # mail(:to => recipient, :subject => "New account information")
# end
# end
+ #
+ # Which will (if it had both a <tt>.text.erb</tt> and <tt>.html.erb</tt> tempalte in the view
+ # directory), send a complete <tt>multipart/mixed</tt> email with two parts, the first part being
+ # a <tt>multipart/alternative</tt> with the text and HTML email parts inside, and the second being
+ # a <tt>application/pdf</tt> with a Base64 encoded copy of the file.pdf book with the filename
+ # +free_book.pdf+.
#
#
# = Configuration options
#
# These options are specified on the class level, like <tt>ActionMailer::Base.template_root = "/my/templates"</tt>
#
- # * <tt>template_root</tt> - Determines the base from which template references will be made.
+ # * <tt>default</tt> - This is a class wide hash of <tt>:key => value</tt> pairs containing
+ # default values for the specified header fields of the <tt>Mail::Message</tt>. You can
+ # specify a default for any valid header for <tt>Mail::Message</tt> and it will be used if
+ # you do not override it. The defaults set by Action Mailer are:
+ # * <tt>:mime_version => "1.0"</tt>
+ # * <tt>:charset => "utf-8",</tt>
+ # * <tt>:content_type => "text/plain",</tt>
+ # * <tt>:parts_order => [ "text/plain", "text/enriched", "text/html" ]</tt>
#
# * <tt>logger</tt> - the logger is used for generating information on the mailing run if available.
# Can be set to nil for no logging. Compatible with both Ruby's own Logger and Log4r loggers.
@@ -236,23 +232,22 @@ module ActionMailer #:nodoc:
# * <tt>deliveries</tt> - Keeps an array of all the emails sent out through the Action Mailer with <tt>delivery_method :test</tt>. Most useful
# for unit and functional testing.
#
- # * <tt>default_charset</tt> - The default charset used for the body and to encode the subject. Defaults to UTF-8. You can also
- # pick a different charset from inside a method with +charset+.
+ # * <tt>default_charset</tt> - This is now deprecated, use the +default+ method above to
+ # set the default +:charset+.
#
- # * <tt>default_content_type</tt> - The default content type used for the main part of the message. Defaults to "text/plain". You
- # can also pick a different content type from inside a method with +content_type+.
+ # * <tt>default_content_type</tt> - This is now deprecated, use the +default+ method above
+ # to set the default +:content_type+.
#
- # * <tt>default_mime_version</tt> - The default mime version used for the message. Defaults to <tt>1.0</tt>. You
- # can also pick a different value from inside a method with +mime_version+.
+ # * <tt>default_mime_version</tt> - This is now deprecated, use the +default+ method above
+ # to set the default +:mime_version+.
#
- # * <tt>default_implicit_parts_order</tt> - When a message is built implicitly (i.e. multiple parts are assembled from templates
- # which specify the content type in their filenames) this variable controls how the parts are ordered. Defaults to
- # <tt>["text/html", "text/enriched", "text/plain"]</tt>. Items that appear first in the array have higher priority in the mail client
- # and appear last in the mime encoded message. You can also pick a different order from inside a method with
- # +implicit_parts_order+.
+ # * <tt>default_implicit_parts_order</tt> - This is now deprecated, use the +default+ method above
+ # to set the default +:parts_order+. Parts Order is used when a message is built implicitly
+ # (i.e. multiple parts are assembled from templates which specify the content type in their
+ # filenames) this variable controls how the parts are ordered.
class Base < AbstractController::Base
- include Quoting
- extend AdvAttrAccessor
+ include DeliveryMethods, Quoting
+ abstract!
include AbstractController::Logger
include AbstractController::Rendering
@@ -260,131 +255,34 @@ module ActionMailer #:nodoc:
include AbstractController::Layouts
include AbstractController::Helpers
include AbstractController::UrlFor
+ include AbstractController::Translation
helper ActionMailer::MailHelper
- include ActionMailer::DeprecatedBody
-
- private_class_method :new #:nodoc:
-
- @@raise_delivery_errors = true
- cattr_accessor :raise_delivery_errors
-
- @@perform_deliveries = true
- cattr_accessor :perform_deliveries
-
- @@deliveries = []
- cattr_accessor :deliveries
-
- @@default_charset = "utf-8"
- cattr_accessor :default_charset
-
- @@default_content_type = "text/plain"
- cattr_accessor :default_content_type
-
- @@default_mime_version = "1.0"
- cattr_accessor :default_mime_version
-
- # This specifies the order that the parts of a multipart email will be. Usually you put
- # text/plain at the top so someone without a MIME capable email reader can read the plain
- # text of your email first.
- #
- # Any content type that is not listed here will be inserted in the order you add them to
- # the email after the content types you list here.
- @@default_implicit_parts_order = [ "text/plain", "text/enriched", "text/html" ]
- cattr_accessor :default_implicit_parts_order
-
- @@protected_instance_variables = %w(@parts @mail)
- cattr_reader :protected_instance_variables
-
- # Specify the BCC addresses for the message
- adv_attr_accessor :bcc
-
- # Specify the CC addresses for the message.
- adv_attr_accessor :cc
- # Specify the charset to use for the message. This defaults to the
- # +default_charset+ specified for ActionMailer::Base.
- adv_attr_accessor :charset
+ include ActionMailer::OldApi
+ include ActionMailer::DeprecatedApi
- # Specify the content type for the message. This defaults to <tt>text/plain</tt>
- # in most cases, but can be automatically set in some situations.
- adv_attr_accessor :content_type
-
- # Specify the from address for the message.
- adv_attr_accessor :from
-
- # Specify the address (if different than the "from" address) to direct
- # replies to this message.
- adv_attr_accessor :reply_to
-
- # Specify additional headers to be added to the message.
- adv_attr_accessor :headers
-
- # Specify the order in which parts should be sorted, based on content-type.
- # This defaults to the value for the +default_implicit_parts_order+.
- adv_attr_accessor :implicit_parts_order
-
- # Defaults to "1.0", but may be explicitly given if needed.
- adv_attr_accessor :mime_version
-
- # The recipient addresses for the message, either as a string (for a single
- # address) or an array (for multiple addresses).
- adv_attr_accessor :recipients
-
- # The date on which the message was sent. If not set (the default), the
- # header will be set by the delivery agent.
- adv_attr_accessor :sent_on
-
- # Specify the subject of the message.
- adv_attr_accessor :subject
-
- # Specify the template name to use for current message. This is the "base"
- # template name, without the extension or directory, and may be used to
- # have multiple mailer methods share the same template.
- adv_attr_accessor :template
-
- # Override the mailer name, which defaults to an inflected version of the
- # mailer's class name. If you want to use a template in a non-standard
- # location, you can use this to specify that location.
- adv_attr_accessor :mailer_name
-
- # Expose the internal mail
- attr_reader :mail
+ private_class_method :new #:nodoc:
- # Alias controller_path to mailer_name so render :partial in views work.
- alias :controller_path :mailer_name
+ extlib_inheritable_accessor :default_params
+ self.default_params = {
+ :mime_version => "1.0",
+ :charset => "utf-8",
+ :content_type => "text/plain",
+ :parts_order => [ "text/plain", "text/enriched", "text/html" ]
+ }
class << self
- attr_writer :mailer_name
-
- delegate :settings, :settings=, :to => ActionMailer::DeliveryMethod::File, :prefix => :file
- delegate :settings, :settings=, :to => ActionMailer::DeliveryMethod::Sendmail, :prefix => :sendmail
- delegate :settings, :settings=, :to => ActionMailer::DeliveryMethod::Smtp, :prefix => :smtp
def mailer_name
@mailer_name ||= name.underscore
end
+ attr_writer :mailer_name
alias :controller_path :mailer_name
- def delivery_method=(method_name)
- @delivery_method = ActionMailer::DeliveryMethod.lookup_method(method_name)
- end
-
- def respond_to?(method_symbol, include_private = false) #:nodoc:
- matches_dynamic_method?(method_symbol) || super
- end
-
- def method_missing(method_symbol, *parameters) #:nodoc:
- if match = matches_dynamic_method?(method_symbol)
- case match[1]
- when 'create' then new(match[2], *parameters).mail
- when 'deliver' then new(match[2], *parameters).deliver!
- when 'new' then nil
- else super
- end
- else
- super
- end
+ def default(value=nil)
+ self.default_params.merge!(value) if value
+ self.default_params
end
# Receives a raw email, parses it into an email object, decodes it,
@@ -406,26 +304,24 @@ module ActionMailer #:nodoc:
end
end
- # Deliver the given mail object directly. This can be used to deliver
- # a preconstructed mail object, like:
- #
- # email = MyMailer.create_some_mail(parameters)
- # email.set_some_obscure_header "frobnicate"
- # MyMailer.deliver(email)
- def deliver(mail)
- new.deliver!(mail)
+ # Delivers a mail object. This is actually called by the <tt>Mail::Message</tt> object
+ # itself through a call back when you call <tt>:deliver</tt> on the Mail::Message,
+ # calling +deliver_mail+ directly and passing an Mail::Message will do nothing.
+ def deliver_mail(mail) #:nodoc:
+ ActiveSupport::Notifications.instrument("action_mailer.deliver") do |payload|
+ self.set_payload_for_mail(payload, mail)
+ yield # Let Mail do the delivery actions
+ end
end
- def template_root
- self.view_paths && self.view_paths.first
+ def respond_to?(method, *args) #:nodoc:
+ super || action_methods.include?(method.to_s)
end
- # Should template root overwrite the whole view_paths?
- def template_root=(root)
- self.view_paths = ActionView::Base.process_view_paths(root)
- end
+ protected
def set_payload_for_mail(payload, mail) #:nodoc:
+ payload[:mailer] = self.name
payload[:message_id] = mail.message_id
payload[:subject] = mail.subject
payload[:to] = mail.to
@@ -436,61 +332,16 @@ module ActionMailer #:nodoc:
payload[:mail] = mail.encoded
end
- private
-
- def matches_dynamic_method?(method_name) #:nodoc:
- method_name = method_name.to_s
- /^(create|deliver)_([_a-z]\w*)/.match(method_name) || /^(new)$/.match(method_name)
+ def method_missing(method, *args) #:nodoc:
+ if action_methods.include?(method.to_s)
+ new(method, *args).message
+ else
+ super
end
- end
-
- # Configure delivery method. Check ActionMailer::DeliveryMethod for more
- # instructions.
- superclass_delegating_reader :delivery_method
- self.delivery_method = :smtp
-
- # Add a part to a multipart message, with the given content-type. The
- # part itself is yielded to the block so that other properties (charset,
- # body, headers, etc.) can be set on it.
- def part(params)
- params = {:content_type => params} if String === params
-
- if custom_headers = params.delete(:headers)
- ActiveSupport::Deprecation.warn('Passing custom headers with :headers => {} is deprecated. ' <<
- 'Please just pass in custom headers directly.', caller[0,10])
- params.merge!(custom_headers)
end
-
- part = Mail::Part.new(params)
- yield part if block_given?
- @parts << part
- end
-
- # Add an attachment to a multipart message. This is simply a part with the
- # content-disposition set to "attachment".
- def attachment(params, &block)
- super # Run deprecation hooks
-
- params = { :content_type => params } if String === params
- params = { :content_disposition => "attachment",
- :content_transfer_encoding => "base64" }.merge(params)
-
- part(params, &block)
end
- # Allow you to set assigns for your template:
- #
- # body :greetings => "Hi"
- #
- # Will make @greetings available in the template to be rendered.
- def body(object=nil)
- returning(super) do # Run deprecation hooks
- if object.is_a?(Hash)
- @assigns_set = true
- object.each { |k, v| instance_variable_set(:"@#{k}", v) }
- end
- end
- end
+ attr_internal :message
# Instantiate a new mailer object. If +method_name+ is not +nil+, the mailer
# will be initialized according to the named method. If not, the mailer will
@@ -498,167 +349,263 @@ module ActionMailer #:nodoc:
# method, for instance).
def initialize(method_name=nil, *args)
super()
+ @_message = Mail.new
process(method_name, *args) if method_name
end
- # Process the mailer via the given +method_name+. The body will be
- # rendered and a new Mail object created.
- def process(method_name, *args)
- initialize_defaults(method_name)
- super
-
- # Create e-mail parts
- create_parts
-
- # Set the subject if not set yet
- @subject ||= I18n.t(:subject, :scope => [:actionmailer, mailer_name, method_name],
- :default => method_name.humanize)
-
- # Build the mail object itself
- create_mail
- end
-
- # Delivers a Mail object. By default, it delivers the cached mail
- # object (from the <tt>create!</tt> method). If no cached mail object exists, and
- # no alternate has been given as the parameter, this will fail.
- def deliver!(mail = @mail)
- raise "no mail object available for delivery!" unless mail
-
- ActiveSupport::Notifications.instrument("action_mailer.deliver",
- :template => template, :mailer => self.class.name) do |payload|
-
- self.class.set_payload_for_mail(payload, mail)
-
- begin
- self.delivery_method.perform_delivery(mail) if perform_deliveries
- rescue Exception => e # Net::SMTP errors or sendmail pipe errors
- raise e if raise_delivery_errors
- end
+ # Allows you to pass random and unusual headers to the new +Mail::Message+ object
+ # which will add them to itself.
+ #
+ # headers['X-Special-Domain-Specific-Header'] = "SecretValue"
+ #
+ # You can also pass a hash into headers of header field names and values, which
+ # will then be set on the Mail::Message object:
+ #
+ # headers 'X-Special-Domain-Specific-Header' => "SecretValue",
+ # 'In-Reply-To' => incoming.message_id
+ #
+ # The resulting Mail::Message will have the following in it's header:
+ #
+ # X-Special-Domain-Specific-Header: SecretValue
+ def headers(args=nil)
+ if args
+ @_message.headers(args)
+ else
+ @_message
end
-
- mail
end
- private
+ # Allows you to add attachments to an email, like so:
+ #
+ # mail.attachments['filename.jpg'] = File.read('/path/to/filename.jpg')
+ #
+ # If you do this, then Mail will take the file name and work out the mime type
+ # set the Content-Type, Content-Disposition, Content-Transfer-Encoding and
+ # base64 encode the contents of the attachment all for you.
+ #
+ # You can also specify overrides if you want by passing a hash instead of a string:
+ #
+ # mail.attachments['filename.jpg'] = {:mime_type => 'application/x-gzip',
+ # :content => File.read('/path/to/filename.jpg')}
+ #
+ # If you want to use a different encoding than Base64, you can pass an encoding in,
+ # but then it is up to you to pass in the content pre-encoded, and don't expect
+ # Mail to know how to decode this data:
+ #
+ # file_content = SpecialEncode(File.read('/path/to/filename.jpg'))
+ # mail.attachments['filename.jpg'] = {:mime_type => 'application/x-gzip',
+ # :encoding => 'SpecialEncoding',
+ # :content => file_content }
+ #
+ # You can also search for specific attachments:
+ #
+ # # By Filename
+ # mail.attachments['filename.jpg'] #=> Mail::Part object or nil
+ #
+ # # or by index
+ # mail.attachments[0] #=> Mail::Part (first attachment)
+ #
+ def attachments
+ @_message.attachments
+ end
- # Render a message but does not set it as mail body. Useful for rendering
- # data for part and attachments.
- #
- # Examples:
- #
- # render_message "special_message"
- # render_message :template => "special_message"
- # render_message :inline => "<%= 'Hi!' %>"
- def render_message(object)
- case object
- when String
- render_to_body(:template => object)
- else
- render_to_body(object)
- end
+ # The main method that creates the message and renders the email templates. There are
+ # two ways to call this method, with a block, or without a block.
+ #
+ # Both methods accept a headers hash. This hash allows you to specify the most used headers
+ # in an email message, these are:
+ #
+ # * <tt>:subject</tt> - The subject of the message, if this is omitted, ActionMailer will
+ # ask the Rails I18n class for a translated <tt>:subject</tt> in the scope of
+ # <tt>[:actionmailer, mailer_scope, action_name]</tt> or if this is missing, will translate the
+ # humanized version of the <tt>action_name</tt>
+ # * <tt>:to</tt> - Who the message is destined for, can be a string of addresses, or an array
+ # of addresses.
+ # * <tt>:from</tt> - Who the message is from
+ # * <tt>:cc</tt> - Who you would like to Carbon-Copy on this email, can be a string of addresses,
+ # or an array of addresses.
+ # * <tt>:bcc</tt> - Who you would like to Blind-Carbon-Copy on this email, can be a string of
+ # addresses, or an array of addresses.
+ # * <tt>:reply_to</tt> - Who to set the Reply-To header of the email to.
+ # * <tt>:date</tt> - The date to say the email was sent on.
+ #
+ # You can set default values for any of the above headers (except :date) by using the <tt>default</tt>
+ # class method:
+ #
+ # class Notifier < ActionMailer::Base
+ # self.default :from => 'no-reply@test.lindsaar.net',
+ # :bcc => 'email_logger@test.lindsaar.net',
+ # :reply_to => 'bounces@test.lindsaar.net'
+ # end
+ #
+ # If you need other headers not listed above, use the <tt>headers['name'] = value</tt> method.
+ #
+ # When a <tt>:return_path</tt> is specified as header, that value will be used as the 'envelope from'
+ # address for the Mail message. Setting this is useful when you want delivery notifications
+ # sent to a different address than the one in <tt>:from</tt>. Mail will actually use the
+ # <tt>:return_path</tt> in preference to the <tt>:sender</tt> in preference to the <tt>:from</tt>
+ # field for the 'envelope from' value.
+ #
+ # If you do not pass a block to the +mail+ method, it will find all templates in the
+ # template path that match the method name that it is being called from, it will then
+ # create parts for each of these templates intelligently, making educated guesses
+ # on correct content type and sequence, and return a fully prepared Mail::Message
+ # ready to call <tt>:deliver</tt> on to send.
+ #
+ # If you do pass a block, you can render specific templates of your choice:
+ #
+ # mail(:to => 'mikel@test.lindsaar.net') do |format|
+ # format.text
+ # format.html
+ # end
+ #
+ # You can even render text directly without using a template:
+ #
+ # mail(:to => 'mikel@test.lindsaar.net') do |format|
+ # format.text { render :text => "Hello Mikel!" }
+ # format.html { render :text => "<h1>Hello Mikel!</h1>" }
+ # end
+ #
+ # Which will render a <tt>multipart/alternative</tt> email with <tt>text/plain</tt> and
+ # <tt>text/html</tt> parts.
+ #
+ # The block syntax also allows you to customize the part headers if desired:
+ #
+ # mail(:to => 'mikel@test.lindsaar.net') do |format|
+ # format.text(:content_transfer_encoding => "base64")
+ # format.html
+ # end
+ #
+ def mail(headers={}, &block)
+ # Guard flag to prevent both the old and the new API from firing
+ # Should be removed when old API is removed
+ @mail_was_called = true
+ m = @_message
+
+ # At the beginning, do not consider class default for parts order neither content_type
+ content_type = headers[:content_type]
+ parts_order = headers[:parts_order]
+
+ # Merge defaults from class
+ headers = headers.reverse_merge(self.class.default)
+ charset = headers[:charset]
+
+ # Quote fields
+ headers[:subject] ||= default_i18n_subject
+ quote_fields!(headers, charset)
+
+ # Render the templates and blocks
+ responses, explicit_order = collect_responses_and_parts_order(headers, &block)
+ create_parts_from_responses(m, responses, charset)
+
+ # Finally setup content type and parts order
+ m.content_type = set_content_type(m, content_type, headers[:content_type])
+ m.charset = charset
+
+ if m.multipart?
+ parts_order ||= explicit_order || headers[:parts_order]
+ m.body.set_sort_order(parts_order)
+ m.body.sort_parts!
end
- # Set up the default values for the various instance variables of this
- # mailer. Subclasses may override this method to provide different
- # defaults.
- def initialize_defaults(method_name) #:nodoc:
- @charset ||= @@default_charset.dup
- @content_type ||= @@default_content_type.dup
- @implicit_parts_order ||= @@default_implicit_parts_order.dup
- @mime_version ||= @@default_mime_version.dup if @@default_mime_version
+ # Set configure delivery behavior
+ wrap_delivery_behavior!(headers[:delivery_method])
- @mailer_name ||= self.class.mailer_name.dup
- @template ||= method_name
+ # Remove headers already treated and assign all others
+ headers.except!(:subject, :to, :from, :cc, :bcc, :reply_to)
+ headers.except!(:body, :parts_order, :content_type, :charset, :delivery_method)
+ headers.each { |k, v| m[k] = v }
- @parts ||= []
- @headers ||= {}
- @sent_on ||= Time.now
+ m
+ end
- super # Run deprecation hooks
+ protected
+
+ def set_content_type(m, user_content_type, class_default)
+ params = m.content_type_parameters || {}
+ case
+ when user_content_type.present?
+ user_content_type
+ when m.has_attachments?
+ ["multipart", "mixed", params]
+ when m.multipart?
+ ["multipart", "alternative", params]
+ else
+ m.content_type || class_default
end
+ end
- def create_parts #:nodoc:
- super # Run deprecation hooks
-
- if String === response_body
- @parts.unshift create_inline_part(response_body)
- else
- self.class.template_root.find_all(@template, {}, @mailer_name).each do |template|
- @parts << create_inline_part(render_to_body(:_template => template), template.mime_type)
- end
+ def default_i18n_subject #:nodoc:
+ mailer_scope = self.class.mailer_name.gsub('/', '.')
+ I18n.t(:subject, :scope => [:actionmailer, mailer_scope, action_name], :default => action_name.humanize)
+ end
- if @parts.size > 1
- @content_type = "multipart/alternative" if @content_type !~ /^multipart/
- end
+ # TODO: Move this into Mail
+ def quote_fields!(headers, charset) #:nodoc:
+ m = @_message
+ m.subject ||= quote_if_necessary(headers[:subject], charset) if headers[:subject]
+ m.to ||= quote_address_if_necessary(headers[:to], charset) if headers[:to]
+ m.from ||= quote_address_if_necessary(headers[:from], charset) if headers[:from]
+ m.cc ||= quote_address_if_necessary(headers[:cc], charset) if headers[:cc]
+ m.bcc ||= quote_address_if_necessary(headers[:bcc], charset) if headers[:bcc]
+ m.reply_to ||= quote_address_if_necessary(headers[:reply_to], charset) if headers[:reply_to]
+ end
- # If this is a multipart e-mail add the mime_version if it is not
- # already set.
- @mime_version ||= "1.0" if !@parts.empty?
+ def collect_responses_and_parts_order(headers) #:nodoc:
+ responses, parts_order = [], nil
+
+ if block_given?
+ collector = ActionMailer::Collector.new(self) { render(action_name) }
+ yield(collector)
+ parts_order = collector.responses.map { |r| r[:content_type] }
+ responses = collector.responses
+ elsif headers[:body]
+ responses << {
+ :body => headers[:body],
+ :content_type => self.class.default[:content_type] || "text/plain"
+ }
+ else
+ each_template do |template|
+ responses << {
+ :body => render_to_body(:_template => template),
+ :content_type => template.mime_type.to_s
+ }
end
end
- def create_inline_part(body, mime_type=nil) #:nodoc:
- ct = mime_type || "text/plain"
- main_type, sub_type = split_content_type(ct.to_s)
-
- Mail::Part.new(
- :content_type => [main_type, sub_type, {:charset => charset}],
- :content_disposition => "inline",
- :body => body
- )
- end
-
- def create_mail #:nodoc:
- m = Mail.new
-
- m.subject, = quote_any_if_necessary(charset, subject)
- m.to, m.from = quote_any_address_if_necessary(charset, recipients, from)
- m.bcc = quote_address_if_necessary(bcc, charset) unless bcc.nil?
- m.cc = quote_address_if_necessary(cc, charset) unless cc.nil?
- m.reply_to = quote_address_if_necessary(reply_to, charset) unless reply_to.nil?
- m.mime_version = mime_version unless mime_version.nil?
- m.date = sent_on.to_time rescue sent_on if sent_on
-
- headers.each { |k, v| m[k] = v }
-
- real_content_type, ctype_attrs = parse_content_type
- main_type, sub_type = split_content_type(real_content_type)
-
- if @parts.size == 1 && @parts.first.parts.empty?
- m.content_type([main_type, sub_type, ctype_attrs])
- m.body = @parts.first.body.encoded
- else
- @parts.each do |p|
- m.add_part(p)
- end
+ [responses, parts_order]
+ end
- m.body.set_sort_order(@implicit_parts_order)
- m.body.sort_parts!
+ def each_template(&block) #:nodoc:
+ self.class.view_paths.each do |load_paths|
+ templates = load_paths.find_all(action_name, {}, self.class.mailer_name)
+ templates = templates.uniq_by { |t| t.details[:formats] }
- if real_content_type =~ /multipart/
- ctype_attrs.delete "charset"
- m.content_type([main_type, sub_type, ctype_attrs])
- end
+ unless templates.empty?
+ templates.each(&block)
+ return
end
-
- m.content_transfer_encoding = '8bit' unless m.body.only_us_ascii?
-
- @mail = m
- end
-
- def split_content_type(ct) #:nodoc:
- ct.to_s.split("/")
end
+ end
- def parse_content_type(defaults=nil) #:nodoc:
- if @content_type.blank?
- [ nil, {} ]
- else
- ctype, *attrs = @content_type.split(/;\s*/)
- attrs = attrs.inject({}) { |h,s| k,v = s.split(/\=/, 2); h[k] = v; h }
- [ctype, {"charset" => @charset}.merge(attrs)]
- end
+ def create_parts_from_responses(m, responses, charset) #:nodoc:
+ if responses.size == 1 && !m.has_attachments?
+ responses[0].each { |k,v| m[k] = v }
+ elsif responses.size > 1 && m.has_attachments?
+ container = Mail::Part.new
+ container.content_type = "multipart/alternative"
+ responses.each { |r| insert_part(container, r, charset) }
+ m.add_part(container)
+ else
+ responses.each { |r| insert_part(m, r, charset) }
end
+ end
+
+ def insert_part(container, response, charset) #:nodoc:
+ response[:charset] ||= charset
+ part = Mail::Part.new(response)
+ container.add_part(part)
+ end
end
end
diff --git a/actionmailer/lib/action_mailer/collector.rb b/actionmailer/lib/action_mailer/collector.rb
new file mode 100644
index 0000000000..5431efccfe
--- /dev/null
+++ b/actionmailer/lib/action_mailer/collector.rb
@@ -0,0 +1,36 @@
+require 'abstract_controller/collector'
+require 'active_support/core_ext/hash/reverse_merge'
+require 'active_support/core_ext/array/extract_options'
+
+module ActionMailer #:nodoc:
+ class Collector
+ include AbstractController::Collector
+ attr_reader :responses
+
+ def initialize(context, &block)
+ @context = context
+ @responses = []
+ @default_render = block
+ @default_formats = context.formats
+ end
+
+ def any(*args, &block)
+ options = args.extract_options!
+ raise "You have to supply at least one format" if args.empty?
+ args.each { |type| send(type, options.dup, &block) }
+ end
+ alias :all :any
+
+ def custom(mime, options={}, &block)
+ options.reverse_merge!(:content_type => mime.to_s)
+ @context.formats = [mime.to_sym]
+ options[:body] = if block
+ block.call
+ else
+ @default_render.call
+ end
+ @responses << options
+ @context.formats = @default_formats
+ end
+ end
+end \ No newline at end of file
diff --git a/actionmailer/lib/action_mailer/delivery_method.rb b/actionmailer/lib/action_mailer/delivery_method.rb
deleted file mode 100644
index 4f7d3afc3c..0000000000
--- a/actionmailer/lib/action_mailer/delivery_method.rb
+++ /dev/null
@@ -1,56 +0,0 @@
-require 'active_support/core_ext/class'
-
-module ActionMailer
- module DeliveryMethod
- autoload :File, 'action_mailer/delivery_method/file'
- autoload :Sendmail, 'action_mailer/delivery_method/sendmail'
- autoload :Smtp, 'action_mailer/delivery_method/smtp'
- autoload :Test, 'action_mailer/delivery_method/test'
-
- # Creates a new DeliveryMethod object according to the given options.
- #
- # If no arguments are passed to this method, then a new
- # ActionMailer::DeliveryMethod::Stmp object will be returned.
- #
- # If you pass a Symbol as the first argument, then a corresponding
- # delivery method class under the ActionMailer::DeliveryMethod namespace
- # will be created.
- # For example:
- #
- # ActionMailer::DeliveryMethod.lookup_method(:sendmail)
- # # => returns a new ActionMailer::DeliveryMethod::Sendmail object
- #
- # If the first argument is not a Symbol, then it will simply be returned:
- #
- # ActionMailer::DeliveryMethod.lookup_method(MyOwnDeliveryMethod.new)
- # # => returns MyOwnDeliveryMethod.new
- def self.lookup_method(delivery_method)
- case delivery_method
- when Symbol
- method_name = delivery_method.to_s.camelize
- method_class = ActionMailer::DeliveryMethod.const_get(method_name)
- method_class.new
- when nil # default
- Smtp.new
- else
- delivery_method
- end
- end
-
- # An abstract delivery method class. There are multiple delivery method classes.
- # See the classes under the ActionMailer::DeliveryMethod, e.g.
- # ActionMailer::DeliveryMethod::Smtp.
- # Smtp is the default delivery method for production
- # while Test is used in testing.
- #
- # each delivery method exposes just one method
- #
- # delivery_method = ActionMailer::DeliveryMethod::Smtp.new
- # delivery_method.perform_delivery(mail) # send the mail via smtp
- #
- class Method
- superclass_delegating_accessor :settings
- self.settings = {}
- end
- end
-end
diff --git a/actionmailer/lib/action_mailer/delivery_method/file.rb b/actionmailer/lib/action_mailer/delivery_method/file.rb
deleted file mode 100644
index 571e32df49..0000000000
--- a/actionmailer/lib/action_mailer/delivery_method/file.rb
+++ /dev/null
@@ -1,21 +0,0 @@
-require 'tmpdir'
-
-module ActionMailer
- module DeliveryMethod
-
- # A delivery method implementation which writes all mails to a file.
- class File < Method
- self.settings = {
- :location => defined?(Rails.root) ? "#{Rails.root}/tmp/mails" : "#{Dir.tmpdir}/mails"
- }
-
- def perform_delivery(mail)
- FileUtils.mkdir_p settings[:location]
-
- mail.destinations.uniq.each do |to|
- ::File.open(::File.join(settings[:location], to), 'a') { |f| f.write(mail) }
- end
- end
- end
- end
-end
diff --git a/actionmailer/lib/action_mailer/delivery_method/sendmail.rb b/actionmailer/lib/action_mailer/delivery_method/sendmail.rb
deleted file mode 100644
index db55af79f1..0000000000
--- a/actionmailer/lib/action_mailer/delivery_method/sendmail.rb
+++ /dev/null
@@ -1,22 +0,0 @@
-module ActionMailer
- module DeliveryMethod
-
- # A delivery method implementation which sends via sendmail.
- class Sendmail < Method
- self.settings = {
- :location => '/usr/sbin/sendmail',
- :arguments => '-i -t'
- }
-
- def perform_delivery(mail)
- sendmail_args = settings[:arguments]
- sendmail_args += " -f \"#{mail['return-path']}\"" if mail['return-path']
- IO.popen("#{settings[:location]} #{sendmail_args}","w+") do |sm|
- sm.print(mail.encoded.gsub(/\r/, ''))
- sm.flush
- end
- end
- end
-
- end
-end
diff --git a/actionmailer/lib/action_mailer/delivery_method/smtp.rb b/actionmailer/lib/action_mailer/delivery_method/smtp.rb
deleted file mode 100644
index af30c498b5..0000000000
--- a/actionmailer/lib/action_mailer/delivery_method/smtp.rb
+++ /dev/null
@@ -1,30 +0,0 @@
-require 'net/smtp'
-
-module ActionMailer
- module DeliveryMethod
- # A delivery method implementation which sends via smtp.
- class Smtp < Method
- self.settings = {
- :address => "localhost",
- :port => 25,
- :domain => 'localhost.localdomain',
- :user_name => nil,
- :password => nil,
- :authentication => nil,
- :enable_starttls_auto => true,
- }
-
- def perform_delivery(mail)
- destinations = mail.destinations
- sender = (mail['return-path'] && mail['return-path'].address) || mail['from']
-
- smtp = Net::SMTP.new(settings[:address], settings[:port])
- smtp.enable_starttls_auto if settings[:enable_starttls_auto] && smtp.respond_to?(:enable_starttls_auto)
- smtp.start(settings[:domain], settings[:user_name], settings[:password],
- settings[:authentication]) do |smtp|
- smtp.sendmail(mail.encoded, sender, destinations)
- end
- end
- end
- end
-end
diff --git a/actionmailer/lib/action_mailer/delivery_method/test.rb b/actionmailer/lib/action_mailer/delivery_method/test.rb
deleted file mode 100644
index 6e3239d52a..0000000000
--- a/actionmailer/lib/action_mailer/delivery_method/test.rb
+++ /dev/null
@@ -1,12 +0,0 @@
-module ActionMailer
- module DeliveryMethod
-
- # A delivery method implementation designed for testing, which just appends each record to the :deliveries array
- class Test < Method
- def perform_delivery(mail)
- ActionMailer::Base.deliveries << mail
- end
- end
-
- end
-end
diff --git a/actionmailer/lib/action_mailer/delivery_methods.rb b/actionmailer/lib/action_mailer/delivery_methods.rb
new file mode 100644
index 0000000000..f6321a240c
--- /dev/null
+++ b/actionmailer/lib/action_mailer/delivery_methods.rb
@@ -0,0 +1,90 @@
+require 'tmpdir'
+
+module ActionMailer
+ # This modules handles everything related to the delivery, from registering new
+ # delivery methods to configuring the mail object to be send.
+ module DeliveryMethods
+ extend ActiveSupport::Concern
+
+ included do
+ extlib_inheritable_accessor :delivery_methods, :delivery_method,
+ :instance_writer => false
+
+ # Do not make this inheritable, because we always want it to propagate
+ cattr_accessor :raise_delivery_errors
+ self.raise_delivery_errors = true
+
+ cattr_accessor :perform_deliveries
+ self.perform_deliveries = true
+
+ self.delivery_methods = {}
+ self.delivery_method = :smtp
+
+ add_delivery_method :smtp, Mail::SMTP,
+ :address => "localhost",
+ :port => 25,
+ :domain => 'localhost.localdomain',
+ :user_name => nil,
+ :password => nil,
+ :authentication => nil,
+ :enable_starttls_auto => true
+
+ add_delivery_method :file, Mail::FileDelivery,
+ :location => defined?(Rails.root) ? "#{Rails.root}/tmp/mails" : "#{Dir.tmpdir}/mails"
+
+ add_delivery_method :sendmail, Mail::Sendmail,
+ :location => '/usr/sbin/sendmail',
+ :arguments => '-i -t'
+
+ add_delivery_method :test, Mail::TestMailer
+ end
+
+ module ClassMethods
+ # Provides a list of emails that have been delivered by Mail::TestMailer
+ delegate :deliveries, :deliveries=, :to => Mail::TestMailer
+
+ # Adds a new delivery method through the given class using the given symbol
+ # as alias and the default options supplied:
+ #
+ # Example:
+ #
+ # add_delivery_method :sendmail, Mail::Sendmail,
+ # :location => '/usr/sbin/sendmail',
+ # :arguments => '-i -t'
+ #
+ def add_delivery_method(symbol, klass, default_options={})
+ unless respond_to?(:"#{symbol}_settings")
+ extlib_inheritable_accessor(:"#{symbol}_settings", :instance_writer => false)
+ end
+
+ send(:"#{symbol}_settings=", default_options)
+ self.delivery_methods[symbol.to_sym] = klass
+ end
+
+ def wrap_delivery_behavior(mail, method=nil) #:nodoc:
+ method ||= self.delivery_method
+ mail.delivery_handler = self
+
+ case method
+ when NilClass
+ raise "Delivery method cannot be nil"
+ when Symbol
+ if klass = delivery_methods[method.to_sym]
+ mail.delivery_method(klass, send(:"#{method}_settings"))
+ else
+ raise "Invalid delivery method #{method.inspect}"
+ end
+ else
+ mail.delivery_method(method)
+ end
+
+ mail.perform_deliveries = perform_deliveries
+ mail.raise_delivery_errors = raise_delivery_errors
+ end
+ end
+
+ def wrap_delivery_behavior!(*args) #:nodoc:
+ self.class.wrap_delivery_behavior(message, *args)
+ end
+ end
+end \ No newline at end of file
diff --git a/actionmailer/lib/action_mailer/deprecated_api.rb b/actionmailer/lib/action_mailer/deprecated_api.rb
new file mode 100644
index 0000000000..54ad18f796
--- /dev/null
+++ b/actionmailer/lib/action_mailer/deprecated_api.rb
@@ -0,0 +1,139 @@
+module ActionMailer
+ # This is the API which is deprecated and is going to be removed on Rails 3.1 release.
+ # Part of the old API will be deprecated after 3.1, for a smoother deprecation process.
+ # Chech those in OldApi instead.
+ module DeprecatedApi #:nodoc:
+ extend ActiveSupport::Concern
+
+ included do
+ [:charset, :content_type, :mime_version, :implicit_parts_order].each do |method|
+ class_eval <<-FILE, __FILE__, __LINE__ + 1
+ def self.default_#{method}
+ @@default_#{method}
+ end
+
+ def self.default_#{method}=(value)
+ ActiveSupport::Deprecation.warn "ActionMailer::Base.default_#{method}=value is deprecated, " <<
+ "use default :#{method} => value instead"
+ @@default_#{method} = value
+ end
+
+ @@default_#{method} = nil
+ FILE
+ end
+ end
+
+ module ClassMethods
+ # Deliver the given mail object directly. This can be used to deliver
+ # a preconstructed mail object, like:
+ #
+ # email = MyMailer.create_some_mail(parameters)
+ # email.set_some_obscure_header "frobnicate"
+ # MyMailer.deliver(email)
+ def deliver(mail, show_warning=true)
+ if show_warning
+ ActiveSupport::Deprecation.warn "#{self}.deliver is deprecated, call " <<
+ "deliver in the mailer instance instead", caller[0,2]
+ end
+
+ raise "no mail object available for delivery!" unless mail
+ wrap_delivery_behavior(mail)
+ mail.deliver
+ mail
+ end
+
+ def template_root
+ self.view_paths && self.view_paths.first
+ end
+
+ def template_root=(root)
+ ActiveSupport::Deprecation.warn "template_root= is deprecated, use view_paths.unshift instead", caller[0,2]
+ self.view_paths = ActionView::Base.process_view_paths(root)
+ end
+
+ def respond_to?(method_symbol, include_private = false)
+ matches_dynamic_method?(method_symbol) || super
+ end
+
+ def method_missing(method_symbol, *parameters)
+ if match = matches_dynamic_method?(method_symbol)
+ case match[1]
+ when 'create'
+ ActiveSupport::Deprecation.warn "#{self}.create_#{match[2]} is deprecated, " <<
+ "use #{self}.#{match[2]} instead", caller[0,2]
+ new(match[2], *parameters).message
+ when 'deliver'
+ ActiveSupport::Deprecation.warn "#{self}.deliver_#{match[2]} is deprecated, " <<
+ "use #{self}.#{match[2]}.deliver instead", caller[0,2]
+ new(match[2], *parameters).message.deliver
+ else super
+ end
+ else
+ super
+ end
+ end
+
+ private
+
+ def matches_dynamic_method?(method_name)
+ method_name = method_name.to_s
+ /^(create|deliver)_([_a-z]\w*)/.match(method_name) || /^(new)$/.match(method_name)
+ end
+ end
+
+ # Delivers a Mail object. By default, it delivers the cached mail
+ # object (from the <tt>create!</tt> method). If no cached mail object exists, and
+ # no alternate has been given as the parameter, this will fail.
+ def deliver!(mail = @_message)
+ ActiveSupport::Deprecation.warn "Calling deliver in the AM::Base object is deprecated, " <<
+ "please call deliver in the Mail instance", caller[0,2]
+ self.class.deliver(mail, false)
+ end
+ alias :deliver :deliver!
+
+ def render(*args)
+ options = args.last.is_a?(Hash) ? args.last : {}
+
+ if options[:body].is_a?(Hash)
+ ActiveSupport::Deprecation.warn(':body in render deprecated. Please use instance ' <<
+ 'variables as assigns instead', caller[0,1])
+
+ options[:body].each { |k,v| instance_variable_set(:"@#{k}", v) }
+ end
+ super
+ end
+
+ # Render a message but does not set it as mail body. Useful for rendering
+ # data for part and attachments.
+ #
+ # Examples:
+ #
+ # render_message "special_message"
+ # render_message :template => "special_message"
+ # render_message :inline => "<%= 'Hi!' %>"
+ #
+ def render_message(*args)
+ ActiveSupport::Deprecation.warn "render_message is deprecated, use render instead", caller[0,2]
+ render(*args)
+ end
+
+ private
+
+ def initialize_defaults(*)
+ @charset ||= self.class.default_charset.try(:dup)
+ @content_type ||= self.class.default_content_type.try(:dup)
+ @implicit_parts_order ||= self.class.default_implicit_parts_order.try(:dup)
+ @mime_version ||= self.class.default_mime_version.try(:dup)
+ super
+ end
+
+ def create_parts
+ if @body.is_a?(Hash) && !@body.empty?
+ ActiveSupport::Deprecation.warn "Giving a hash to body is deprecated, please use instance variables instead", caller[0,2]
+ @body.each { |k, v| instance_variable_set(:"@#{k}", v) }
+ end
+ super
+ end
+
+ end
+end
diff --git a/actionmailer/lib/action_mailer/deprecated_body.rb b/actionmailer/lib/action_mailer/deprecated_body.rb
deleted file mode 100644
index 5379b33a54..0000000000
--- a/actionmailer/lib/action_mailer/deprecated_body.rb
+++ /dev/null
@@ -1,46 +0,0 @@
-module ActionMailer
- # TODO Remove this module all together in a next release. Ensure that super
- # hooks and @assigns_set in ActionMailer::Base are removed as well.
- module DeprecatedBody
- extend ActionMailer::AdvAttrAccessor
-
- # Define the body of the message. This is either a Hash (in which case it
- # specifies the variables to pass to the template when it is rendered),
- # or a string, in which case it specifies the actual text of the message.
- adv_attr_accessor :body
-
- def initialize_defaults(method_name)
- @body ||= {}
- end
-
- def attachment(params, &block)
- if params[:body]
- ActiveSupport::Deprecation.warn('attachment :body => "string" is deprecated. To set the body of an attachment ' <<
- 'please use :data instead, like attachment :data => "string"', caller[0,10])
- params[:data] = params.delete(:body)
- end
- end
-
- def create_parts
- if String === @body && !defined?(@assigns_set)
- ActiveSupport::Deprecation.warn('body(String) is deprecated. To set the body with a text ' <<
- 'call render(:text => "body")', caller[0,10])
- self.response_body = @body
- elsif self.response_body
- @body = self.response_body
- end
- end
-
- def render(*args)
- options = args.last.is_a?(Hash) ? args.last : {}
- if options[:body]
- ActiveSupport::Deprecation.warn(':body in render deprecated. Please call body ' <<
- 'with a hash instead', caller[0,1])
-
- body options.delete(:body)
- end
-
- super
- end
- end
-end
diff --git a/actionmailer/lib/action_mailer/mail_helper.rb b/actionmailer/lib/action_mailer/mail_helper.rb
index 701dc34431..ab5c3469b2 100644
--- a/actionmailer/lib/action_mailer/mail_helper.rb
+++ b/actionmailer/lib/action_mailer/mail_helper.rb
@@ -17,8 +17,13 @@ module ActionMailer
end
# Access the mailer instance.
- def mailer #:nodoc:
- @controller
+ def mailer
+ @_controller
+ end
+
+ # Access the message instance.
+ def message
+ @_message
end
end
end
diff --git a/actionmailer/lib/action_mailer/old_api.rb b/actionmailer/lib/action_mailer/old_api.rb
new file mode 100644
index 0000000000..936ceb0dd6
--- /dev/null
+++ b/actionmailer/lib/action_mailer/old_api.rb
@@ -0,0 +1,248 @@
+require 'active_support/core_ext/object/try'
+
+module ActionMailer
+ module OldApi #:nodoc:
+ extend ActiveSupport::Concern
+
+ included do
+ extend ActionMailer::AdvAttrAccessor
+
+ @@protected_instance_variables = %w(@parts)
+ cattr_reader :protected_instance_variables
+
+ # Specify the BCC addresses for the message
+ adv_attr_accessor :bcc
+
+ # Specify the CC addresses for the message.
+ adv_attr_accessor :cc
+
+ # Specify the charset to use for the message. This defaults to the
+ # +default_charset+ specified for ActionMailer::Base.
+ adv_attr_accessor :charset
+
+ # Specify the content type for the message. This defaults to <tt>text/plain</tt>
+ # in most cases, but can be automatically set in some situations.
+ adv_attr_accessor :content_type
+
+ # Specify the from address for the message.
+ adv_attr_accessor :from
+
+ # Specify the address (if different than the "from" address) to direct
+ # replies to this message.
+ adv_attr_accessor :reply_to
+
+ # Specify additional headers to be added to the message.
+ adv_attr_accessor :headers
+
+ # Specify the order in which parts should be sorted, based on content-type.
+ # This defaults to the value for the +default_implicit_parts_order+.
+ adv_attr_accessor :implicit_parts_order
+
+ # Defaults to "1.0", but may be explicitly given if needed.
+ adv_attr_accessor :mime_version
+
+ # The recipient addresses for the message, either as a string (for a single
+ # address) or an array (for multiple addresses).
+ adv_attr_accessor :recipients
+
+ # The date on which the message was sent. If not set (the default), the
+ # header will be set by the delivery agent.
+ adv_attr_accessor :sent_on
+
+ # Specify the subject of the message.
+ adv_attr_accessor :subject
+
+ # Specify the template name to use for current message. This is the "base"
+ # template name, without the extension or directory, and may be used to
+ # have multiple mailer methods share the same template.
+ adv_attr_accessor :template
+
+ # Override the mailer name, which defaults to an inflected version of the
+ # mailer's class name. If you want to use a template in a non-standard
+ # location, you can use this to specify that location.
+ adv_attr_accessor :mailer_name
+
+ # Define the body of the message. This is either a Hash (in which case it
+ # specifies the variables to pass to the template when it is rendered),
+ # or a string, in which case it specifies the actual text of the message.
+ adv_attr_accessor :body
+
+ # Alias controller_path to mailer_name so render :partial in views work.
+ alias :controller_path :mailer_name
+ end
+
+ def process(method_name, *args)
+ initialize_defaults(method_name)
+ super
+ unless @mail_was_called
+ create_parts
+ create_mail
+ end
+ @_message
+ end
+
+ # Add a part to a multipart message, with the given content-type. The
+ # part itself is yielded to the block so that other properties (charset,
+ # body, headers, etc.) can be set on it.
+ def part(params)
+ params = {:content_type => params} if String === params
+
+ if custom_headers = params.delete(:headers)
+ params.merge!(custom_headers)
+ end
+
+ part = Mail::Part.new(params)
+
+ yield part if block_given?
+ @parts << part
+ end
+
+ # Add an attachment to a multipart message. This is simply a part with the
+ # content-disposition set to "attachment".
+ def attachment(params, &block)
+ params = { :content_type => params } if String === params
+
+ params[:content] ||= params.delete(:data) || params.delete(:body)
+
+ if params[:filename]
+ params = normalize_file_hash(params)
+ else
+ params = normalize_nonfile_hash(params)
+ end
+
+ part(params, &block)
+ end
+
+ protected
+
+ def normalize_nonfile_hash(params)
+ content_disposition = "attachment;"
+
+ mime_type = params.delete(:mime_type)
+
+ if content_type = params.delete(:content_type)
+ content_type = "#{mime_type || content_type};"
+ end
+
+ params[:body] = params.delete(:data) if params[:data]
+
+ { :content_type => content_type,
+ :content_disposition => content_disposition }.merge(params)
+ end
+
+ def normalize_file_hash(params)
+ filename = File.basename(params.delete(:filename))
+ content_disposition = "attachment; filename=\"#{File.basename(filename)}\""
+
+ mime_type = params.delete(:mime_type)
+
+ if (content_type = params.delete(:content_type)) && (content_type !~ /filename=/)
+ content_type = "#{mime_type || content_type}; filename=\"#{filename}\""
+ end
+
+ params[:body] = params.delete(:data) if params[:data]
+
+ { :content_type => content_type,
+ :content_disposition => content_disposition }.merge(params)
+ end
+
+ def create_mail
+ m = @_message
+
+ quote_fields!({:subject => subject, :to => recipients, :from => from,
+ :bcc => bcc, :cc => cc, :reply_to => reply_to}, charset)
+
+ m.mime_version = mime_version unless mime_version.nil?
+ m.date = sent_on.to_time rescue sent_on if sent_on
+
+ @headers.each { |k, v| m[k] = v }
+
+ real_content_type, ctype_attrs = parse_content_type
+ main_type, sub_type = split_content_type(real_content_type)
+
+ if @parts.size == 1 && @parts.first.parts.empty?
+ m.content_type([main_type, sub_type, ctype_attrs])
+ m.body = @parts.first.body.encoded
+ else
+ @parts.each do |p|
+ m.add_part(p)
+ end
+
+ m.body.set_sort_order(@implicit_parts_order)
+ m.body.sort_parts!
+
+ if real_content_type =~ /multipart/
+ ctype_attrs.delete "charset"
+ m.content_type([main_type, sub_type, ctype_attrs])
+ end
+ end
+
+ wrap_delivery_behavior!
+ m.content_transfer_encoding = '8bit' unless m.body.only_us_ascii?
+
+ @_message
+ end
+
+ # Set up the default values for the various instance variables of this
+ # mailer. Subclasses may override this method to provide different
+ # defaults.
+ def initialize_defaults(method_name)
+ @charset ||= self.class.default[:charset].try(:dup)
+ @content_type ||= self.class.default[:content_type].try(:dup)
+ @implicit_parts_order ||= self.class.default[:parts_order].try(:dup)
+ @mime_version ||= self.class.default[:mime_version].try(:dup)
+
+ @mailer_name ||= self.class.mailer_name.dup
+ @template ||= method_name
+ @mail_was_called = false
+
+ @parts ||= []
+ @headers ||= {}
+ @sent_on ||= Time.now
+ @body ||= {}
+ end
+
+ def create_parts
+ if String === @body
+ @parts.unshift create_inline_part(@body)
+ elsif @parts.empty? || @parts.all? { |p| p.content_disposition =~ /^attachment/ }
+ self.class.view_paths.first.find_all(@template, {}, @mailer_name).each do |template|
+ @parts << create_inline_part(render_to_body(:_template => template), template.mime_type)
+ end
+
+ if @parts.size > 1
+ @content_type = "multipart/alternative" if @content_type !~ /^multipart/
+ end
+
+ # If this is a multipart e-mail add the mime_version if it is not
+ # already set.
+ @mime_version ||= "1.0" if !@parts.empty?
+ end
+ end
+
+ def create_inline_part(body, mime_type=nil)
+ ct = mime_type || "text/plain"
+ main_type, sub_type = split_content_type(ct.to_s)
+
+ Mail::Part.new(
+ :content_type => [main_type, sub_type, {:charset => charset}],
+ :content_disposition => "inline",
+ :body => body
+ )
+ end
+
+ def split_content_type(ct)
+ ct.to_s.split("/")
+ end
+
+ def parse_content_type(defaults=nil)
+ if @content_type.blank?
+ [ nil, {} ]
+ else
+ ctype, *attrs = @content_type.split(/;\s*/)
+ attrs = attrs.inject({}) { |h,s| k,v = s.split(/\=/, 2); h[k] = v; h }
+ [ctype, {"charset" => @charset}.merge(attrs)]
+ end
+ end
+ end
+end
diff --git a/actionmailer/lib/action_mailer/railtie.rb b/actionmailer/lib/action_mailer/railtie.rb
index b05d21ae5d..7ed1519e36 100644
--- a/actionmailer/lib/action_mailer/railtie.rb
+++ b/actionmailer/lib/action_mailer/railtie.rb
@@ -3,26 +3,19 @@ require "rails"
module ActionMailer
class Railtie < Rails::Railtie
- plugin_name :action_mailer
+ railtie_name :action_mailer
require "action_mailer/railties/subscriber"
subscriber ActionMailer::Railties::Subscriber.new
- initializer "action_mailer.set_configs" do |app|
- app.config.action_mailer.each do |k,v|
- ActionMailer::Base.send "#{k}=", v
- end
- end
-
- # TODO: ActionController::Base.logger should delegate to its own config.logger
initializer "action_mailer.logger" do
ActionMailer::Base.logger ||= Rails.logger
end
- initializer "action_mailer.view_paths" do |app|
- # TODO: this should be combined with the logic for default config.action_mailer.view_paths
- view_path = ActionView::PathSet.type_cast(app.config.view_path, app.config.cache_classes)
- ActionMailer::Base.template_root = view_path if ActionMailer::Base.view_paths.blank?
+ initializer "action_mailer.set_configs" do |app|
+ app.config.action_mailer.each do |k,v|
+ ActionMailer::Base.send "#{k}=", v
+ end
end
end
end \ No newline at end of file
diff --git a/actionmailer/lib/action_mailer/test_case.rb b/actionmailer/lib/action_mailer/test_case.rb
index 0ca4f5494e..7c4033a125 100644
--- a/actionmailer/lib/action_mailer/test_case.rb
+++ b/actionmailer/lib/action_mailer/test_case.rb
@@ -37,7 +37,7 @@ module ActionMailer
def initialize_test_deliveries
ActionMailer::Base.delivery_method = :test
ActionMailer::Base.perform_deliveries = true
- ActionMailer::Base.deliveries = []
+ ActionMailer::Base.deliveries.clear
end
def set_expected_mail
diff --git a/actionmailer/lib/action_mailer/test_helper.rb b/actionmailer/lib/action_mailer/test_helper.rb
index f234c0248c..3a1612442f 100644
--- a/actionmailer/lib/action_mailer/test_helper.rb
+++ b/actionmailer/lib/action_mailer/test_helper.rb
@@ -58,7 +58,6 @@ module ActionMailer
end
end
-# TODO: Deprecate this
module Test
module Unit
class TestCase
diff --git a/actionmailer/lib/action_mailer/tmail_compat.rb b/actionmailer/lib/action_mailer/tmail_compat.rb
index 2fd25ff145..c6efdc53b6 100644
--- a/actionmailer/lib/action_mailer/tmail_compat.rb
+++ b/actionmailer/lib/action_mailer/tmail_compat.rb
@@ -2,19 +2,27 @@ module Mail
class Message
def set_content_type(*args)
- STDERR.puts("Message#set_content_type is deprecated, please just call Message#content_type with the same arguments.\n#{caller}")
+ ActiveSupport::Deprecation.warn('Message#set_content_type is deprecated, please just call ' <<
+ 'Message#content_type with the same arguments', caller[0,2])
content_type(*args)
end
alias :old_transfer_encoding :transfer_encoding
def transfer_encoding(value = nil)
if value
- STDERR.puts("Message#transfer_encoding is deprecated, please call Message#content_transfer_encoding with the same arguments.\n#{caller}")
+ ActiveSupport::Deprecation.warn('Message#transfer_encoding is deprecated, please call ' <<
+ 'Message#content_transfer_encoding with the same arguments', caller[0,2])
content_transfer_encoding(value)
else
old_transfer_encoding
end
end
+ def original_filename
+ ActiveSupport::Deprecation.warn('Message#original_filename is deprecated, ' <<
+ 'please call Message#filename', caller[0,2])
+ filename
+ end
+
end
end \ No newline at end of file
diff --git a/actionmailer/lib/action_mailer/vendor/text-format-0.6.3/text/format.rb b/actionmailer/lib/action_mailer/vendor/text-format-0.6.3/text/format.rb
deleted file mode 100755
index 81cc7906d8..0000000000
--- a/actionmailer/lib/action_mailer/vendor/text-format-0.6.3/text/format.rb
+++ /dev/null
@@ -1,1467 +0,0 @@
-#--
-# Text::Format for Ruby
-# Version 0.63
-#
-# Copyright (c) 2002 - 2003 Austin Ziegler
-#
-# $Id: format.rb,v 1.1.1.1 2004/10/14 11:59:57 webster132 Exp $
-#
-# ==========================================================================
-# Revision History ::
-# YYYY.MM.DD Change ID Developer
-# Description
-# --------------------------------------------------------------------------
-# 2002.10.18 Austin Ziegler
-# Fixed a minor problem with tabs not being counted. Changed
-# abbreviations from Hash to Array to better suit Ruby's
-# capabilities. Fixed problems with the way that Array arguments
-# are handled in calls to the major object types, excepting in
-# Text::Format#expand and Text::Format#unexpand (these will
-# probably need to be fixed).
-# 2002.10.30 Austin Ziegler
-# Fixed the ordering of the <=> for binary tests. Fixed
-# Text::Format#expand and Text::Format#unexpand to handle array
-# arguments better.
-# 2003.01.24 Austin Ziegler
-# Fixed a problem with Text::Format::RIGHT_FILL handling where a
-# single word is larger than #columns. Removed Comparable
-# capabilities (<=> doesn't make sense; == does). Added Symbol
-# equivalents for the Hash initialization. Hash initialization has
-# been modified so that values are set as follows (Symbols are
-# highest priority; strings are middle; defaults are lowest):
-# @columns = arg[:columns] || arg['columns'] || @columns
-# Added #hard_margins, #split_rules, #hyphenator, and #split_words.
-# 2003.02.07 Austin Ziegler
-# Fixed the installer for proper case-sensitive handling.
-# 2003.03.28 Austin Ziegler
-# Added the ability for a hyphenator to receive the formatter
-# object. Fixed a bug for strings matching /\A\s*\Z/ failing
-# entirely. Fixed a test case failing under 1.6.8.
-# 2003.04.04 Austin Ziegler
-# Handle the case of hyphenators returning nil for first/rest.
-# 2003.09.17 Austin Ziegler
-# Fixed a problem where #paragraphs(" ") was raising
-# NoMethodError.
-#
-# ==========================================================================
-#++
-
-module Text #:nodoc:
- # Text::Format for Ruby is copyright 2002 - 2005 by Austin Ziegler. It
- # is available under Ruby's licence, the Perl Artistic licence, or the
- # GNU GPL version 2 (or at your option, any later version). As a
- # special exception, for use with official Rails (provided by the
- # rubyonrails.org development team) and any project created with
- # official Rails, the following alternative MIT-style licence may be
- # used:
- #
- # == Text::Format Licence for Rails and Rails Applications
- # Permission is hereby granted, free of charge, to any person
- # obtaining a copy of this software and associated documentation files
- # (the "Software"), to deal in the Software without restriction,
- # including without limitation the rights to use, copy, modify, merge,
- # publish, distribute, sublicense, and/or sell copies of the Software,
- # and to permit persons to whom the Software is furnished to do so,
- # subject to the following conditions:
- #
- # * The names of its contributors may not be used to endorse or
- # promote products derived from this software without specific prior
- # written permission.
- #
- # The above copyright notice and this permission notice shall be
- # included in all copies or substantial portions of the Software.
- #
- # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- # EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- # NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
- # BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
- # ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
- # CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
- # SOFTWARE.
- class Format
- VERSION = '0.63'
-
- # Local abbreviations. More can be added with Text::Format.abbreviations
- ABBREV = [ 'Mr', 'Mrs', 'Ms', 'Jr', 'Sr' ]
-
- # Formatting values
- LEFT_ALIGN = 0
- RIGHT_ALIGN = 1
- RIGHT_FILL = 2
- JUSTIFY = 3
-
- # Word split modes (only applies when #hard_margins is true).
- SPLIT_FIXED = 1
- SPLIT_CONTINUATION = 2
- SPLIT_HYPHENATION = 4
- SPLIT_CONTINUATION_FIXED = SPLIT_CONTINUATION | SPLIT_FIXED
- SPLIT_HYPHENATION_FIXED = SPLIT_HYPHENATION | SPLIT_FIXED
- SPLIT_HYPHENATION_CONTINUATION = SPLIT_HYPHENATION | SPLIT_CONTINUATION
- SPLIT_ALL = SPLIT_HYPHENATION | SPLIT_CONTINUATION | SPLIT_FIXED
-
- # Words forcibly split by Text::Format will be stored as split words.
- # This class represents a word forcibly split.
- class SplitWord
- # The word that was split.
- attr_reader :word
- # The first part of the word that was split.
- attr_reader :first
- # The remainder of the word that was split.
- attr_reader :rest
-
- def initialize(word, first, rest) #:nodoc:
- @word = word
- @first = first
- @rest = rest
- end
- end
-
- private
- LEQ_RE = /[.?!]['"]?$/
-
- def brk_re(i) #:nodoc:
- %r/((?:\S+\s+){#{i}})(.+)/
- end
-
- def posint(p) #:nodoc:
- p.to_i.abs
- end
-
- public
- # Compares two Text::Format objects. All settings of the objects are
- # compared *except* #hyphenator. Generated results (e.g., #split_words)
- # are not compared, either.
- def ==(o)
- (@text == o.text) &&
- (@columns == o.columns) &&
- (@left_margin == o.left_margin) &&
- (@right_margin == o.right_margin) &&
- (@hard_margins == o.hard_margins) &&
- (@split_rules == o.split_rules) &&
- (@first_indent == o.first_indent) &&
- (@body_indent == o.body_indent) &&
- (@tag_text == o.tag_text) &&
- (@tabstop == o.tabstop) &&
- (@format_style == o.format_style) &&
- (@extra_space == o.extra_space) &&
- (@tag_paragraph == o.tag_paragraph) &&
- (@nobreak == o.nobreak) &&
- (@abbreviations == o.abbreviations) &&
- (@nobreak_regex == o.nobreak_regex)
- end
-
- # The text to be manipulated. Note that value is optional, but if the
- # formatting functions are called without values, this text is what will
- # be formatted.
- #
- # *Default*:: <tt>[]</tt>
- # <b>Used in</b>:: All methods
- attr_accessor :text
-
- # The total width of the format area. The margins, indentation, and text
- # are formatted into this space.
- #
- # COLUMNS
- # <-------------------------------------------------------------->
- # <-----------><------><---------------------------><------------>
- # left margin indent text is formatted into here right margin
- #
- # *Default*:: <tt>72</tt>
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>,
- # <tt>#center</tt>
- attr_reader :columns
-
- # The total width of the format area. The margins, indentation, and text
- # are formatted into this space. The value provided is silently
- # converted to a positive integer.
- #
- # COLUMNS
- # <-------------------------------------------------------------->
- # <-----------><------><---------------------------><------------>
- # left margin indent text is formatted into here right margin
- #
- # *Default*:: <tt>72</tt>
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>,
- # <tt>#center</tt>
- def columns=(c)
- @columns = posint(c)
- end
-
- # The number of spaces used for the left margin.
- #
- # columns
- # <-------------------------------------------------------------->
- # <-----------><------><---------------------------><------------>
- # LEFT MARGIN indent text is formatted into here right margin
- #
- # *Default*:: <tt>0</tt>
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>,
- # <tt>#center</tt>
- attr_reader :left_margin
-
- # The number of spaces used for the left margin. The value provided is
- # silently converted to a positive integer value.
- #
- # columns
- # <-------------------------------------------------------------->
- # <-----------><------><---------------------------><------------>
- # LEFT MARGIN indent text is formatted into here right margin
- #
- # *Default*:: <tt>0</tt>
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>,
- # <tt>#center</tt>
- def left_margin=(left)
- @left_margin = posint(left)
- end
-
- # The number of spaces used for the right margin.
- #
- # columns
- # <-------------------------------------------------------------->
- # <-----------><------><---------------------------><------------>
- # left margin indent text is formatted into here RIGHT MARGIN
- #
- # *Default*:: <tt>0</tt>
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>,
- # <tt>#center</tt>
- attr_reader :right_margin
-
- # The number of spaces used for the right margin. The value provided is
- # silently converted to a positive integer value.
- #
- # columns
- # <-------------------------------------------------------------->
- # <-----------><------><---------------------------><------------>
- # left margin indent text is formatted into here RIGHT MARGIN
- #
- # *Default*:: <tt>0</tt>
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>,
- # <tt>#center</tt>
- def right_margin=(r)
- @right_margin = posint(r)
- end
-
- # The number of spaces to indent the first line of a paragraph.
- #
- # columns
- # <-------------------------------------------------------------->
- # <-----------><------><---------------------------><------------>
- # left margin INDENT text is formatted into here right margin
- #
- # *Default*:: <tt>4</tt>
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>
- attr_reader :first_indent
-
- # The number of spaces to indent the first line of a paragraph. The
- # value provided is silently converted to a positive integer value.
- #
- # columns
- # <-------------------------------------------------------------->
- # <-----------><------><---------------------------><------------>
- # left margin INDENT text is formatted into here right margin
- #
- # *Default*:: <tt>4</tt>
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>
- def first_indent=(f)
- @first_indent = posint(f)
- end
-
- # The number of spaces to indent all lines after the first line of a
- # paragraph.
- #
- # columns
- # <-------------------------------------------------------------->
- # <-----------><------><---------------------------><------------>
- # left margin INDENT text is formatted into here right margin
- #
- # *Default*:: <tt>0</tt>
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>
- attr_reader :body_indent
-
- # The number of spaces to indent all lines after the first line of
- # a paragraph. The value provided is silently converted to a
- # positive integer value.
- #
- # columns
- # <-------------------------------------------------------------->
- # <-----------><------><---------------------------><------------>
- # left margin INDENT text is formatted into here right margin
- #
- # *Default*:: <tt>0</tt>
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>
- def body_indent=(b)
- @body_indent = posint(b)
- end
-
- # Normally, words larger than the format area will be placed on a line
- # by themselves. Setting this to +true+ will force words larger than the
- # format area to be split into one or more "words" each at most the size
- # of the format area. The first line and the original word will be
- # placed into <tt>#split_words</tt>. Note that this will cause the
- # output to look *similar* to a #format_style of JUSTIFY. (Lines will be
- # filled as much as possible.)
- #
- # *Default*:: +false+
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>
- attr_accessor :hard_margins
-
- # An array of words split during formatting if #hard_margins is set to
- # +true+.
- # #split_words << Text::Format::SplitWord.new(word, first, rest)
- attr_reader :split_words
-
- # The object responsible for hyphenating. It must respond to
- # #hyphenate_to(word, size) or #hyphenate_to(word, size, formatter) and
- # return an array of the word split into two parts; if there is a
- # hyphenation mark to be applied, responsibility belongs to the
- # hyphenator object. The size is the MAXIMUM size permitted, including
- # any hyphenation marks. If the #hyphenate_to method has an arity of 3,
- # the formatter will be provided to the method. This allows the
- # hyphenator to make decisions about the hyphenation based on the
- # formatting rules.
- #
- # *Default*:: +nil+
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>
- attr_reader :hyphenator
-
- # The object responsible for hyphenating. It must respond to
- # #hyphenate_to(word, size) and return an array of the word hyphenated
- # into two parts. The size is the MAXIMUM size permitted, including any
- # hyphenation marks.
- #
- # *Default*:: +nil+
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>
- def hyphenator=(h)
- raise ArgumentError, "#{h.inspect} is not a valid hyphenator." unless h.respond_to?(:hyphenate_to)
- arity = h.method(:hyphenate_to).arity
- raise ArgumentError, "#{h.inspect} must have exactly two or three arguments." unless [2, 3].include?(arity)
- @hyphenator = h
- @hyphenator_arity = arity
- end
-
- # Specifies the split mode; used only when #hard_margins is set to
- # +true+. Allowable values are:
- # [+SPLIT_FIXED+] The word will be split at the number of
- # characters needed, with no marking at all.
- # repre
- # senta
- # ion
- # [+SPLIT_CONTINUATION+] The word will be split at the number of
- # characters needed, with a C-style continuation
- # character. If a word is the only item on a
- # line and it cannot be split into an
- # appropriate size, SPLIT_FIXED will be used.
- # repr\
- # esen\
- # tati\
- # on
- # [+SPLIT_HYPHENATION+] The word will be split according to the
- # hyphenator specified in #hyphenator. If there
- # is no #hyphenator specified, works like
- # SPLIT_CONTINUATION. The example is using
- # TeX::Hyphen. If a word is the only item on a
- # line and it cannot be split into an
- # appropriate size, SPLIT_CONTINUATION mode will
- # be used.
- # rep-
- # re-
- # sen-
- # ta-
- # tion
- #
- # *Default*:: <tt>Text::Format::SPLIT_FIXED</tt>
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>
- attr_reader :split_rules
-
- # Specifies the split mode; used only when #hard_margins is set to
- # +true+. Allowable values are:
- # [+SPLIT_FIXED+] The word will be split at the number of
- # characters needed, with no marking at all.
- # repre
- # senta
- # ion
- # [+SPLIT_CONTINUATION+] The word will be split at the number of
- # characters needed, with a C-style continuation
- # character.
- # repr\
- # esen\
- # tati\
- # on
- # [+SPLIT_HYPHENATION+] The word will be split according to the
- # hyphenator specified in #hyphenator. If there
- # is no #hyphenator specified, works like
- # SPLIT_CONTINUATION. The example is using
- # TeX::Hyphen as the #hyphenator.
- # rep-
- # re-
- # sen-
- # ta-
- # tion
- #
- # These values can be bitwise ORed together (e.g., <tt>SPLIT_FIXED |
- # SPLIT_CONTINUATION</tt>) to provide fallback split methods. In the
- # example given, an attempt will be made to split the word using the
- # rules of SPLIT_CONTINUATION; if there is not enough room, the word
- # will be split with the rules of SPLIT_FIXED. These combinations are
- # also available as the following values:
- # * +SPLIT_CONTINUATION_FIXED+
- # * +SPLIT_HYPHENATION_FIXED+
- # * +SPLIT_HYPHENATION_CONTINUATION+
- # * +SPLIT_ALL+
- #
- # *Default*:: <tt>Text::Format::SPLIT_FIXED</tt>
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>
- def split_rules=(s)
- raise ArgumentError, "Invalid value provided for split_rules." if ((s < SPLIT_FIXED) || (s > SPLIT_ALL))
- @split_rules = s
- end
-
- # Indicates whether sentence terminators should be followed by a single
- # space (+false+), or two spaces (+true+).
- #
- # *Default*:: +false+
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>
- attr_accessor :extra_space
-
- # Defines the current abbreviations as an array. This is only used if
- # extra_space is turned on.
- #
- # If one is abbreviating "President" as "Pres." (abbreviations =
- # ["Pres"]), then the results of formatting will be as illustrated in
- # the table below:
- #
- # extra_space | include? | !include?
- # true | Pres. Lincoln | Pres. Lincoln
- # false | Pres. Lincoln | Pres. Lincoln
- #
- # *Default*:: <tt>{}</tt>
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>
- attr_accessor :abbreviations
-
- # Indicates whether the formatting of paragraphs should be done with
- # tagged paragraphs. Useful only with <tt>#tag_text</tt>.
- #
- # *Default*:: +false+
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>
- attr_accessor :tag_paragraph
-
- # The array of text to be placed before each paragraph when
- # <tt>#tag_paragraph</tt> is +true+. When <tt>#format()</tt> is called,
- # only the first element of the array is used. When <tt>#paragraphs</tt>
- # is called, then each entry in the array will be used once, with
- # corresponding paragraphs. If the tag elements are exhausted before the
- # text is exhausted, then the remaining paragraphs will not be tagged.
- # Regardless of indentation settings, a blank line will be inserted
- # between all paragraphs when <tt>#tag_paragraph</tt> is +true+.
- #
- # *Default*:: <tt>[]</tt>
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>
- attr_accessor :tag_text
-
- # Indicates whether or not the non-breaking space feature should be
- # used.
- #
- # *Default*:: +false+
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>
- attr_accessor :nobreak
-
- # A hash which holds the regular expressions on which spaces should not
- # be broken. The hash is set up such that the key is the first word and
- # the value is the second word.
- #
- # For example, if +nobreak_regex+ contains the following hash:
- #
- # { '^Mrs?\.$' => '\S+$', '^\S+$' => '^(?:S|J)r\.$'}
- #
- # Then "Mr. Jones", "Mrs. Jones", and "Jones Jr." would not be broken.
- # If this simple matching algorithm indicates that there should not be a
- # break at the current end of line, then a backtrack is done until there
- # are two words on which line breaking is permitted. If two such words
- # are not found, then the end of the line will be broken *regardless*.
- # If there is a single word on the current line, then no backtrack is
- # done and the word is stuck on the end.
- #
- # *Default*:: <tt>{}</tt>
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>
- attr_accessor :nobreak_regex
-
- # Indicates the number of spaces that a single tab represents.
- #
- # *Default*:: <tt>8</tt>
- # <b>Used in</b>:: <tt>#expand</tt>, <tt>#unexpand</tt>,
- # <tt>#paragraphs</tt>
- attr_reader :tabstop
-
- # Indicates the number of spaces that a single tab represents.
- #
- # *Default*:: <tt>8</tt>
- # <b>Used in</b>:: <tt>#expand</tt>, <tt>#unexpand</tt>,
- # <tt>#paragraphs</tt>
- def tabstop=(t)
- @tabstop = posint(t)
- end
-
- # Specifies the format style. Allowable values are:
- # [+LEFT_ALIGN+] Left justified, ragged right.
- # |A paragraph that is|
- # |left aligned.|
- # [+RIGHT_ALIGN+] Right justified, ragged left.
- # |A paragraph that is|
- # | right aligned.|
- # [+RIGHT_FILL+] Left justified, right ragged, filled to width by
- # spaces. (Essentially the same as +LEFT_ALIGN+ except
- # that lines are padded on the right.)
- # |A paragraph that is|
- # |left aligned. |
- # [+JUSTIFY+] Fully justified, words filled to width by spaces,
- # except the last line.
- # |A paragraph that|
- # |is justified.|
- #
- # *Default*:: <tt>Text::Format::LEFT_ALIGN</tt>
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>
- attr_reader :format_style
-
- # Specifies the format style. Allowable values are:
- # [+LEFT_ALIGN+] Left justified, ragged right.
- # |A paragraph that is|
- # |left aligned.|
- # [+RIGHT_ALIGN+] Right justified, ragged left.
- # |A paragraph that is|
- # | right aligned.|
- # [+RIGHT_FILL+] Left justified, right ragged, filled to width by
- # spaces. (Essentially the same as +LEFT_ALIGN+ except
- # that lines are padded on the right.)
- # |A paragraph that is|
- # |left aligned. |
- # [+JUSTIFY+] Fully justified, words filled to width by spaces.
- # |A paragraph that|
- # |is justified.|
- #
- # *Default*:: <tt>Text::Format::LEFT_ALIGN</tt>
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>
- def format_style=(fs)
- raise ArgumentError, "Invalid value provided for format_style." if ((fs < LEFT_ALIGN) || (fs > JUSTIFY))
- @format_style = fs
- end
-
- # Indicates that the format style is left alignment.
- #
- # *Default*:: +true+
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>
- def left_align?
- return @format_style == LEFT_ALIGN
- end
-
- # Indicates that the format style is right alignment.
- #
- # *Default*:: +false+
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>
- def right_align?
- return @format_style == RIGHT_ALIGN
- end
-
- # Indicates that the format style is right fill.
- #
- # *Default*:: +false+
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>
- def right_fill?
- return @format_style == RIGHT_FILL
- end
-
- # Indicates that the format style is full justification.
- #
- # *Default*:: +false+
- # <b>Used in</b>:: <tt>#format</tt>, <tt>#paragraphs</tt>
- def justify?
- return @format_style == JUSTIFY
- end
-
- # The default implementation of #hyphenate_to implements
- # SPLIT_CONTINUATION.
- def hyphenate_to(word, size)
- [word[0 .. (size - 2)] + "\\", word[(size - 1) .. -1]]
- end
-
- private
- def __do_split_word(word, size) #:nodoc:
- [word[0 .. (size - 1)], word[size .. -1]]
- end
-
- def __format(to_wrap) #:nodoc:
- words = to_wrap.split(/\s+/).compact
- words.shift if words[0].nil? or words[0].empty?
- to_wrap = []
-
- abbrev = false
- width = @columns - @first_indent - @left_margin - @right_margin
- indent_str = ' ' * @first_indent
- first_line = true
- line = words.shift
- abbrev = __is_abbrev(line) unless line.nil? || line.empty?
-
- while w = words.shift
- if (w.size + line.size < (width - 1)) ||
- ((line !~ LEQ_RE || abbrev) && (w.size + line.size < width))
- line << " " if (line =~ LEQ_RE) && (not abbrev)
- line << " #{w}"
- else
- line, w = __do_break(line, w) if @nobreak
- line, w = __do_hyphenate(line, w, width) if @hard_margins
- if w.index(/\s+/)
- w, *w2 = w.split(/\s+/)
- words.unshift(w2)
- words.flatten!
- end
- to_wrap << __make_line(line, indent_str, width, w.nil?) unless line.nil?
- if first_line
- first_line = false
- width = @columns - @body_indent - @left_margin - @right_margin
- indent_str = ' ' * @body_indent
- end
- line = w
- end
-
- abbrev = __is_abbrev(w) unless w.nil?
- end
-
- loop do
- break if line.nil? or line.empty?
- line, w = __do_hyphenate(line, w, width) if @hard_margins
- to_wrap << __make_line(line, indent_str, width, w.nil?)
- line = w
- end
-
- if (@tag_paragraph && (to_wrap.size > 0)) then
- clr = %r{`(\w+)'}.match([caller(1)].flatten[0])[1]
- clr = "" if clr.nil?
-
- if ((not @tag_text[0].nil?) && (@tag_cur.size < 1) &&
- (clr != "__paragraphs")) then
- @tag_cur = @tag_text[0]
- end
-
- fchar = /(\S)/.match(to_wrap[0])[1]
- white = to_wrap[0].index(fchar)
- if ((white - @left_margin - 1) > @tag_cur.size) then
- white = @tag_cur.size + @left_margin
- to_wrap[0].gsub!(/^ {#{white}}/, "#{' ' * @left_margin}#{@tag_cur}")
- else
- to_wrap.unshift("#{' ' * @left_margin}#{@tag_cur}\n")
- end
- end
- to_wrap.join('')
- end
-
- # format lines in text into paragraphs with each element of @wrap a
- # paragraph; uses Text::Format.format for the formatting
- def __paragraphs(to_wrap) #:nodoc:
- if ((@first_indent == @body_indent) || @tag_paragraph) then
- p_end = "\n"
- else
- p_end = ''
- end
-
- cnt = 0
- ret = []
- to_wrap.each do |tw|
- @tag_cur = @tag_text[cnt] if @tag_paragraph
- @tag_cur = '' if @tag_cur.nil?
- line = __format(tw)
- ret << "#{line}#{p_end}" if (not line.nil?) && (line.size > 0)
- cnt += 1
- end
-
- ret[-1].chomp! unless ret.empty?
- ret.join('')
- end
-
- # center text using spaces on left side to pad it out empty lines
- # are preserved
- def __center(to_center) #:nodoc:
- tabs = 0
- width = @columns - @left_margin - @right_margin
- centered = []
- to_center.each do |tc|
- s = tc.strip
- tabs = s.count("\t")
- tabs = 0 if tabs.nil?
- ct = ((width - s.size - (tabs * @tabstop) + tabs) / 2)
- ct = (width - @left_margin - @right_margin) - ct
- centered << "#{s.rjust(ct)}\n"
- end
- centered.join('')
- end
-
- # expand tabs to spaces should be similar to Text::Tabs::expand
- def __expand(to_expand) #:nodoc:
- expanded = []
- to_expand.split("\n").each { |te| expanded << te.gsub(/\t/, ' ' * @tabstop) }
- expanded.join('')
- end
-
- def __unexpand(to_unexpand) #:nodoc:
- unexpanded = []
- to_unexpand.split("\n").each { |tu| unexpanded << tu.gsub(/ {#{@tabstop}}/, "\t") }
- unexpanded.join('')
- end
-
- def __is_abbrev(word) #:nodoc:
- # remove period if there is one.
- w = word.gsub(/\.$/, '') unless word.nil?
- return true if (!@extra_space || ABBREV.include?(w) || @abbreviations.include?(w))
- false
- end
-
- def __make_line(line, indent, width, last = false) #:nodoc:
- lmargin = " " * @left_margin
- fill = " " * (width - line.size) if right_fill? && (line.size <= width)
-
- if (justify? && ((not line.nil?) && (not line.empty?)) && line =~ /\S+\s+\S+/ && !last)
- spaces = width - line.size
- words = line.split(/(\s+)/)
- ws = spaces / (words.size / 2)
- spaces = spaces % (words.size / 2) if ws > 0
- words.reverse.each do |rw|
- next if (rw =~ /^\S/)
- rw.sub!(/^/, " " * ws)
- next unless (spaces > 0)
- rw.sub!(/^/, " ")
- spaces -= 1
- end
- line = words.join('')
- end
- line = "#{lmargin}#{indent}#{line}#{fill}\n" unless line.nil?
- if right_align? && (not line.nil?)
- line.sub(/^/, " " * (@columns - @right_margin - (line.size - 1)))
- else
- line
- end
- end
-
- def __do_hyphenate(line, next_line, width) #:nodoc:
- rline = line.dup rescue line
- rnext = next_line.dup rescue next_line
- loop do
- if rline.size == width
- break
- elsif rline.size > width
- words = rline.strip.split(/\s+/)
- word = words[-1].dup
- size = width - rline.size + word.size
- if (size <= 0)
- words[-1] = nil
- rline = words.join(' ').strip
- rnext = "#{word} #{rnext}".strip
- next
- end
-
- first = rest = nil
-
- if ((@split_rules & SPLIT_HYPHENATION) != 0)
- if @hyphenator_arity == 2
- first, rest = @hyphenator.hyphenate_to(word, size)
- else
- first, rest = @hyphenator.hyphenate_to(word, size, self)
- end
- end
-
- if ((@split_rules & SPLIT_CONTINUATION) != 0) and first.nil?
- first, rest = self.hyphenate_to(word, size)
- end
-
- if ((@split_rules & SPLIT_FIXED) != 0) and first.nil?
- first.nil? or @split_rules == SPLIT_FIXED
- first, rest = __do_split_word(word, size)
- end
-
- if first.nil?
- words[-1] = nil
- rest = word
- else
- words[-1] = first
- @split_words << SplitWord.new(word, first, rest)
- end
- rline = words.join(' ').strip
- rnext = "#{rest} #{rnext}".strip
- break
- else
- break if rnext.nil? or rnext.empty? or rline.nil? or rline.empty?
- words = rnext.split(/\s+/)
- word = words.shift
- size = width - rline.size - 1
-
- if (size <= 0)
- rnext = "#{word} #{words.join(' ')}".strip
- break
- end
-
- first = rest = nil
-
- if ((@split_rules & SPLIT_HYPHENATION) != 0)
- if @hyphenator_arity == 2
- first, rest = @hyphenator.hyphenate_to(word, size)
- else
- first, rest = @hyphenator.hyphenate_to(word, size, self)
- end
- end
-
- first, rest = self.hyphenate_to(word, size) if ((@split_rules & SPLIT_CONTINUATION) != 0) and first.nil?
-
- first, rest = __do_split_word(word, size) if ((@split_rules & SPLIT_FIXED) != 0) and first.nil?
-
- if (rline.size + (first ? first.size : 0)) < width
- @split_words << SplitWord.new(word, first, rest)
- rline = "#{rline} #{first}".strip
- rnext = "#{rest} #{words.join(' ')}".strip
- end
- break
- end
- end
- [rline, rnext]
- end
-
- def __do_break(line, next_line) #:nodoc:
- no_brk = false
- words = []
- words = line.split(/\s+/) unless line.nil?
- last_word = words[-1]
-
- @nobreak_regex.each { |k, v| no_brk = ((last_word =~ /#{k}/) and (next_line =~ /#{v}/)) }
-
- if no_brk && words.size > 1
- i = words.size
- while i > 0
- no_brk = false
- @nobreak_regex.each { |k, v| no_brk = ((words[i + 1] =~ /#{k}/) && (words[i] =~ /#{v}/)) }
- i -= 1
- break if not no_brk
- end
- if i > 0
- l = brk_re(i).match(line)
- line.sub!(brk_re(i), l[1])
- next_line = "#{l[2]} #{next_line}"
- line.sub!(/\s+$/, '')
- end
- end
- [line, next_line]
- end
-
- def __create(arg = nil, &block) #:nodoc:
- # Format::Text.new(text-to-wrap)
- @text = arg unless arg.nil?
- # Defaults
- @columns = 72
- @tabstop = 8
- @first_indent = 4
- @body_indent = 0
- @format_style = LEFT_ALIGN
- @left_margin = 0
- @right_margin = 0
- @extra_space = false
- @text = Array.new if @text.nil?
- @tag_paragraph = false
- @tag_text = Array.new
- @tag_cur = ""
- @abbreviations = Array.new
- @nobreak = false
- @nobreak_regex = Hash.new
- @split_words = Array.new
- @hard_margins = false
- @split_rules = SPLIT_FIXED
- @hyphenator = self
- @hyphenator_arity = self.method(:hyphenate_to).arity
-
- instance_eval(&block) unless block.nil?
- end
-
- public
- # Formats text into a nice paragraph format. The text is separated
- # into words and then reassembled a word at a time using the settings
- # of this Format object. If a word is larger than the number of
- # columns available for formatting, then that word will appear on the
- # line by itself.
- #
- # If +to_wrap+ is +nil+, then the value of <tt>#text</tt> will be
- # worked on.
- def format(to_wrap = nil)
- to_wrap = @text if to_wrap.nil?
- if to_wrap.class == Array
- __format(to_wrap[0])
- else
- __format(to_wrap)
- end
- end
-
- # Considers each element of text (provided or internal) as a paragraph.
- # If <tt>#first_indent</tt> is the same as <tt>#body_indent</tt>, then
- # paragraphs will be separated by a single empty line in the result;
- # otherwise, the paragraphs will follow immediately after each other.
- # Uses <tt>#format</tt> to do the heavy lifting.
- def paragraphs(to_wrap = nil)
- to_wrap = @text if to_wrap.nil?
- __paragraphs([to_wrap].flatten)
- end
-
- # Centers the text, preserving empty lines and tabs.
- def center(to_center = nil)
- to_center = @text if to_center.nil?
- __center([to_center].flatten)
- end
-
- # Replaces all tab characters in the text with <tt>#tabstop</tt> spaces.
- def expand(to_expand = nil)
- to_expand = @text if to_expand.nil?
- if to_expand.class == Array
- to_expand.collect { |te| __expand(te) }
- else
- __expand(to_expand)
- end
- end
-
- # Replaces all occurrences of <tt>#tabstop</tt> consecutive spaces
- # with a tab character.
- def unexpand(to_unexpand = nil)
- to_unexpand = @text if to_unexpand.nil?
- if to_unexpand.class == Array
- to_unexpand.collect { |te| v << __unexpand(te) }
- else
- __unexpand(to_unexpand)
- end
- end
-
- # This constructor takes advantage of a technique for Ruby object
- # construction introduced by Andy Hunt and Dave Thomas (see reference),
- # where optional values are set using commands in a block.
- #
- # Text::Format.new {
- # columns = 72
- # left_margin = 0
- # right_margin = 0
- # first_indent = 4
- # body_indent = 0
- # format_style = Text::Format::LEFT_ALIGN
- # extra_space = false
- # abbreviations = {}
- # tag_paragraph = false
- # tag_text = []
- # nobreak = false
- # nobreak_regex = {}
- # tabstop = 8
- # text = nil
- # }
- #
- # As shown above, +arg+ is optional. If +arg+ is specified and is a
- # +String+, then arg is used as the default value of <tt>#text</tt>.
- # Alternately, an existing Text::Format object can be used or a Hash can
- # be used. With all forms, a block can be specified.
- #
- # *Reference*:: "Object Construction and Blocks"
- # <http://www.pragmaticprogrammer.com/ruby/articles/insteval.html>
- #
- def initialize(arg = nil, &block)
- @text = nil
- case arg
- when Text::Format
- __create(arg.text) do
- @columns = arg.columns
- @tabstop = arg.tabstop
- @first_indent = arg.first_indent
- @body_indent = arg.body_indent
- @format_style = arg.format_style
- @left_margin = arg.left_margin
- @right_margin = arg.right_margin
- @extra_space = arg.extra_space
- @tag_paragraph = arg.tag_paragraph
- @tag_text = arg.tag_text
- @abbreviations = arg.abbreviations
- @nobreak = arg.nobreak
- @nobreak_regex = arg.nobreak_regex
- @text = arg.text
- @hard_margins = arg.hard_margins
- @split_words = arg.split_words
- @split_rules = arg.split_rules
- @hyphenator = arg.hyphenator
- end
- instance_eval(&block) unless block.nil?
- when Hash
- __create do
- @columns = arg[:columns] || arg['columns'] || @columns
- @tabstop = arg[:tabstop] || arg['tabstop'] || @tabstop
- @first_indent = arg[:first_indent] || arg['first_indent'] || @first_indent
- @body_indent = arg[:body_indent] || arg['body_indent'] || @body_indent
- @format_style = arg[:format_style] || arg['format_style'] || @format_style
- @left_margin = arg[:left_margin] || arg['left_margin'] || @left_margin
- @right_margin = arg[:right_margin] || arg['right_margin'] || @right_margin
- @extra_space = arg[:extra_space] || arg['extra_space'] || @extra_space
- @text = arg[:text] || arg['text'] || @text
- @tag_paragraph = arg[:tag_paragraph] || arg['tag_paragraph'] || @tag_paragraph
- @tag_text = arg[:tag_text] || arg['tag_text'] || @tag_text
- @abbreviations = arg[:abbreviations] || arg['abbreviations'] || @abbreviations
- @nobreak = arg[:nobreak] || arg['nobreak'] || @nobreak
- @nobreak_regex = arg[:nobreak_regex] || arg['nobreak_regex'] || @nobreak_regex
- @hard_margins = arg[:hard_margins] || arg['hard_margins'] || @hard_margins
- @split_rules = arg[:split_rules] || arg['split_rules'] || @split_rules
- @hyphenator = arg[:hyphenator] || arg['hyphenator'] || @hyphenator
- end
- instance_eval(&block) unless block.nil?
- when String
- __create(arg, &block)
- when NilClass
- __create(&block)
- else
- raise TypeError
- end
- end
- end
-end
-
-if __FILE__ == $0
- require 'test/unit'
-
- class TestText__Format < Test::Unit::TestCase #:nodoc:
- attr_accessor :format_o
-
- GETTYSBURG = <<-'EOS'
- Four score and seven years ago our fathers brought forth on this
- continent a new nation, conceived in liberty and dedicated to the
- proposition that all men are created equal. Now we are engaged in
- a great civil war, testing whether that nation or any nation so
- conceived and so dedicated can long endure. We are met on a great
- battlefield of that war. We have come to dedicate a portion of
- that field as a final resting-place for those who here gave their
- lives that that nation might live. It is altogether fitting and
- proper that we should do this. But in a larger sense, we cannot
- dedicate, we cannot consecrate, we cannot hallow this ground.
- The brave men, living and dead who struggled here have consecrated
- it far above our poor power to add or detract. The world will
- little note nor long remember what we say here, but it can never
- forget what they did here. It is for us the living rather to be
- dedicated here to the unfinished work which they who fought here
- have thus far so nobly advanced. It is rather for us to be here
- dedicated to the great task remaining before us--that from these
- honored dead we take increased devotion to that cause for which
- they gave the last full measure of devotion--that we here highly
- resolve that these dead shall not have died in vain, that this
- nation under God shall have a new birth of freedom, and that
- government of the people, by the people, for the people shall
- not perish from the earth.
-
- -- Pres. Abraham Lincoln, 19 November 1863
- EOS
-
- FIVE_COL = "Four \nscore\nand s\neven \nyears\nago o\nur fa\nthers\nbroug\nht fo\nrth o\nn thi\ns con\ntinen\nt a n\new na\ntion,\nconce\nived \nin li\nberty\nand d\nedica\nted t\no the\npropo\nsitio\nn tha\nt all\nmen a\nre cr\neated\nequal\n. Now\nwe ar\ne eng\naged \nin a \ngreat\ncivil\nwar, \ntesti\nng wh\nether\nthat \nnatio\nn or \nany n\nation\nso co\nnceiv\ned an\nd so \ndedic\nated \ncan l\nong e\nndure\n. We \nare m\net on\na gre\nat ba\nttlef\nield \nof th\nat wa\nr. We\nhave \ncome \nto de\ndicat\ne a p\nortio\nn of \nthat \nfield\nas a \nfinal\nresti\nng-pl\nace f\nor th\nose w\nho he\nre ga\nve th\neir l\nives \nthat \nthat \nnatio\nn mig\nht li\nve. I\nt is \naltog\nether\nfitti\nng an\nd pro\nper t\nhat w\ne sho\nuld d\no thi\ns. Bu\nt in \na lar\nger s\nense,\nwe ca\nnnot \ndedic\nate, \nwe ca\nnnot \nconse\ncrate\n, we \ncanno\nt hal\nlow t\nhis g\nround\n. The\nbrave\nmen, \nlivin\ng and\ndead \nwho s\ntrugg\nled h\nere h\nave c\nonsec\nrated\nit fa\nr abo\nve ou\nr poo\nr pow\ner to\nadd o\nr det\nract.\nThe w\norld \nwill \nlittl\ne not\ne nor\nlong \nremem\nber w\nhat w\ne say\nhere,\nbut i\nt can\nnever\nforge\nt wha\nt the\ny did\nhere.\nIt is\nfor u\ns the\nlivin\ng rat\nher t\no be \ndedic\nated \nhere \nto th\ne unf\ninish\ned wo\nrk wh\nich t\nhey w\nho fo\nught \nhere \nhave \nthus \nfar s\no nob\nly ad\nvance\nd. It\nis ra\nther \nfor u\ns to \nbe he\nre de\ndicat\ned to\nthe g\nreat \ntask \nremai\nning \nbefor\ne us-\n-that\nfrom \nthese\nhonor\ned de\nad we\ntake \nincre\nased \ndevot\nion t\no tha\nt cau\nse fo\nr whi\nch th\ney ga\nve th\ne las\nt ful\nl mea\nsure \nof de\nvotio\nn--th\nat we\nhere \nhighl\ny res\nolve \nthat \nthese\ndead \nshall\nnot h\nave d\nied i\nn vai\nn, th\nat th\nis na\ntion \nunder\nGod s\nhall \nhave \na new\nbirth\nof fr\needom\n, and\nthat \ngover\nnment\nof th\ne peo\nple, \nby th\ne peo\nple, \nfor t\nhe pe\nople \nshall\nnot p\nerish\nfrom \nthe e\narth.\n-- Pr\nes. A\nbraha\nm Lin\ncoln,\n19 No\nvembe\nr 186\n3 \n"
-
- FIVE_CNT = "Four \nscore\nand \nseven\nyears\nago \nour \nfath\\\ners \nbrou\\\nght \nforth\non t\\\nhis \ncont\\\ninent\na new\nnati\\\non, \nconc\\\neived\nin l\\\niber\\\nty a\\\nnd d\\\nedic\\\nated \nto t\\\nhe p\\\nropo\\\nsiti\\\non t\\\nhat \nall \nmen \nare \ncrea\\\nted \nequa\\\nl. N\\\now we\nare \nenga\\\nged \nin a \ngreat\ncivil\nwar, \ntest\\\ning \nwhet\\\nher \nthat \nnati\\\non or\nany \nnati\\\non so\nconc\\\neived\nand \nso d\\\nedic\\\nated \ncan \nlong \nendu\\\nre. \nWe a\\\nre m\\\net on\na gr\\\neat \nbatt\\\nlefi\\\neld \nof t\\\nhat \nwar. \nWe h\\\nave \ncome \nto d\\\nedic\\\nate a\nport\\\nion \nof t\\\nhat \nfield\nas a \nfinal\nrest\\\ning-\\\nplace\nfor \nthose\nwho \nhere \ngave \ntheir\nlives\nthat \nthat \nnati\\\non m\\\night \nlive.\nIt is\nalto\\\ngeth\\\ner f\\\nitti\\\nng a\\\nnd p\\\nroper\nthat \nwe s\\\nhould\ndo t\\\nhis. \nBut \nin a \nlarg\\\ner s\\\nense,\nwe c\\\nannot\ndedi\\\ncate,\nwe c\\\nannot\ncons\\\necra\\\nte, \nwe c\\\nannot\nhall\\\now t\\\nhis \ngrou\\\nnd. \nThe \nbrave\nmen, \nlivi\\\nng a\\\nnd d\\\nead \nwho \nstru\\\nggled\nhere \nhave \ncons\\\necra\\\nted \nit f\\\nar a\\\nbove \nour \npoor \npower\nto a\\\ndd or\ndetr\\\nact. \nThe \nworld\nwill \nlitt\\\nle n\\\note \nnor \nlong \nreme\\\nmber \nwhat \nwe s\\\nay h\\\nere, \nbut \nit c\\\nan n\\\never \nforg\\\net w\\\nhat \nthey \ndid \nhere.\nIt is\nfor \nus t\\\nhe l\\\niving\nrath\\\ner to\nbe d\\\nedic\\\nated \nhere \nto t\\\nhe u\\\nnfin\\\nished\nwork \nwhich\nthey \nwho \nfoug\\\nht h\\\nere \nhave \nthus \nfar \nso n\\\nobly \nadva\\\nnced.\nIt is\nrath\\\ner f\\\nor us\nto be\nhere \ndedi\\\ncated\nto t\\\nhe g\\\nreat \ntask \nrema\\\nining\nbefo\\\nre u\\\ns--t\\\nhat \nfrom \nthese\nhono\\\nred \ndead \nwe t\\\nake \nincr\\\neased\ndevo\\\ntion \nto t\\\nhat \ncause\nfor \nwhich\nthey \ngave \nthe \nlast \nfull \nmeas\\\nure \nof d\\\nevot\\\nion-\\\n-that\nwe h\\\nere \nhigh\\\nly r\\\nesol\\\nve t\\\nhat \nthese\ndead \nshall\nnot \nhave \ndied \nin v\\\nain, \nthat \nthis \nnati\\\non u\\\nnder \nGod \nshall\nhave \na new\nbirth\nof f\\\nreed\\\nom, \nand \nthat \ngove\\\nrnme\\\nnt of\nthe \npeop\\\nle, \nby t\\\nhe p\\\neopl\\\ne, f\\\nor t\\\nhe p\\\neople\nshall\nnot \nperi\\\nsh f\\\nrom \nthe \neart\\\nh. --\nPres.\nAbra\\\nham \nLinc\\\noln, \n19 N\\\novem\\\nber \n1863 \n"
-
- # Tests both abbreviations and abbreviations=
- def test_abbreviations
- abbr = [" Pres. Abraham Lincoln\n", " Pres. Abraham Lincoln\n"]
- assert_nothing_raised { @format_o = Text::Format.new }
- assert_equal([], @format_o.abbreviations)
- assert_nothing_raised { @format_o.abbreviations = [ 'foo', 'bar' ] }
- assert_equal([ 'foo', 'bar' ], @format_o.abbreviations)
- assert_equal(abbr[0], @format_o.format(abbr[0]))
- assert_nothing_raised { @format_o.extra_space = true }
- assert_equal(abbr[1], @format_o.format(abbr[0]))
- assert_nothing_raised { @format_o.abbreviations = [ "Pres" ] }
- assert_equal([ "Pres" ], @format_o.abbreviations)
- assert_equal(abbr[0], @format_o.format(abbr[0]))
- assert_nothing_raised { @format_o.extra_space = false }
- assert_equal(abbr[0], @format_o.format(abbr[0]))
- end
-
- # Tests both body_indent and body_indent=
- def test_body_indent
- assert_nothing_raised { @format_o = Text::Format.new }
- assert_equal(0, @format_o.body_indent)
- assert_nothing_raised { @format_o.body_indent = 7 }
- assert_equal(7, @format_o.body_indent)
- assert_nothing_raised { @format_o.body_indent = -3 }
- assert_equal(3, @format_o.body_indent)
- assert_nothing_raised { @format_o.body_indent = "9" }
- assert_equal(9, @format_o.body_indent)
- assert_nothing_raised { @format_o.body_indent = "-2" }
- assert_equal(2, @format_o.body_indent)
- assert_match(/^ [^ ]/, @format_o.format(GETTYSBURG).split("\n")[1])
- end
-
- # Tests both columns and columns=
- def test_columns
- assert_nothing_raised { @format_o = Text::Format.new }
- assert_equal(72, @format_o.columns)
- assert_nothing_raised { @format_o.columns = 7 }
- assert_equal(7, @format_o.columns)
- assert_nothing_raised { @format_o.columns = -3 }
- assert_equal(3, @format_o.columns)
- assert_nothing_raised { @format_o.columns = "9" }
- assert_equal(9, @format_o.columns)
- assert_nothing_raised { @format_o.columns = "-2" }
- assert_equal(2, @format_o.columns)
- assert_nothing_raised { @format_o.columns = 40 }
- assert_equal(40, @format_o.columns)
- assert_match(/this continent$/,
- @format_o.format(GETTYSBURG).split("\n")[1])
- end
-
- # Tests both extra_space and extra_space=
- def test_extra_space
- assert_nothing_raised { @format_o = Text::Format.new }
- assert(!@format_o.extra_space)
- assert_nothing_raised { @format_o.extra_space = true }
- assert(@format_o.extra_space)
- # The behaviour of extra_space is tested in test_abbreviations. There
- # is no need to reproduce it here.
- end
-
- # Tests both first_indent and first_indent=
- def test_first_indent
- assert_nothing_raised { @format_o = Text::Format.new }
- assert_equal(4, @format_o.first_indent)
- assert_nothing_raised { @format_o.first_indent = 7 }
- assert_equal(7, @format_o.first_indent)
- assert_nothing_raised { @format_o.first_indent = -3 }
- assert_equal(3, @format_o.first_indent)
- assert_nothing_raised { @format_o.first_indent = "9" }
- assert_equal(9, @format_o.first_indent)
- assert_nothing_raised { @format_o.first_indent = "-2" }
- assert_equal(2, @format_o.first_indent)
- assert_match(/^ [^ ]/, @format_o.format(GETTYSBURG).split("\n")[0])
- end
-
- def test_format_style
- assert_nothing_raised { @format_o = Text::Format.new }
- assert_equal(Text::Format::LEFT_ALIGN, @format_o.format_style)
- assert_match(/^November 1863$/,
- @format_o.format(GETTYSBURG).split("\n")[-1])
- assert_nothing_raised {
- @format_o.format_style = Text::Format::RIGHT_ALIGN
- }
- assert_equal(Text::Format::RIGHT_ALIGN, @format_o.format_style)
- assert_match(/^ +November 1863$/,
- @format_o.format(GETTYSBURG).split("\n")[-1])
- assert_nothing_raised {
- @format_o.format_style = Text::Format::RIGHT_FILL
- }
- assert_equal(Text::Format::RIGHT_FILL, @format_o.format_style)
- assert_match(/^November 1863 +$/,
- @format_o.format(GETTYSBURG).split("\n")[-1])
- assert_nothing_raised { @format_o.format_style = Text::Format::JUSTIFY }
- assert_equal(Text::Format::JUSTIFY, @format_o.format_style)
- assert_match(/^of freedom, and that government of the people, by the people, for the$/,
- @format_o.format(GETTYSBURG).split("\n")[-3])
- assert_raise(ArgumentError) { @format_o.format_style = 33 }
- end
-
- def test_tag_paragraph
- assert_nothing_raised { @format_o = Text::Format.new }
- assert(!@format_o.tag_paragraph)
- assert_nothing_raised { @format_o.tag_paragraph = true }
- assert(@format_o.tag_paragraph)
- assert_not_equal(@format_o.paragraphs([GETTYSBURG, GETTYSBURG]),
- Text::Format.new.paragraphs([GETTYSBURG, GETTYSBURG]))
- end
-
- def test_tag_text
- assert_nothing_raised { @format_o = Text::Format.new }
- assert_equal([], @format_o.tag_text)
- assert_equal(@format_o.format(GETTYSBURG),
- Text::Format.new.format(GETTYSBURG))
- assert_nothing_raised {
- @format_o.tag_paragraph = true
- @format_o.tag_text = ["Gettysburg Address", "---"]
- }
- assert_not_equal(@format_o.format(GETTYSBURG),
- Text::Format.new.format(GETTYSBURG))
- assert_not_equal(@format_o.paragraphs([GETTYSBURG, GETTYSBURG]),
- Text::Format.new.paragraphs([GETTYSBURG, GETTYSBURG]))
- assert_not_equal(@format_o.paragraphs([GETTYSBURG, GETTYSBURG,
- GETTYSBURG]),
- Text::Format.new.paragraphs([GETTYSBURG, GETTYSBURG,
- GETTYSBURG]))
- end
-
- def test_justify?
- assert_nothing_raised { @format_o = Text::Format.new }
- assert(!@format_o.justify?)
- assert_nothing_raised {
- @format_o.format_style = Text::Format::RIGHT_ALIGN
- }
- assert(!@format_o.justify?)
- assert_nothing_raised {
- @format_o.format_style = Text::Format::RIGHT_FILL
- }
- assert(!@format_o.justify?)
- assert_nothing_raised {
- @format_o.format_style = Text::Format::JUSTIFY
- }
- assert(@format_o.justify?)
- # The format testing is done in test_format_style
- end
-
- def test_left_align?
- assert_nothing_raised { @format_o = Text::Format.new }
- assert(@format_o.left_align?)
- assert_nothing_raised {
- @format_o.format_style = Text::Format::RIGHT_ALIGN
- }
- assert(!@format_o.left_align?)
- assert_nothing_raised {
- @format_o.format_style = Text::Format::RIGHT_FILL
- }
- assert(!@format_o.left_align?)
- assert_nothing_raised { @format_o.format_style = Text::Format::JUSTIFY }
- assert(!@format_o.left_align?)
- # The format testing is done in test_format_style
- end
-
- def test_left_margin
- assert_nothing_raised { @format_o = Text::Format.new }
- assert_equal(0, @format_o.left_margin)
- assert_nothing_raised { @format_o.left_margin = -3 }
- assert_equal(3, @format_o.left_margin)
- assert_nothing_raised { @format_o.left_margin = "9" }
- assert_equal(9, @format_o.left_margin)
- assert_nothing_raised { @format_o.left_margin = "-2" }
- assert_equal(2, @format_o.left_margin)
- assert_nothing_raised { @format_o.left_margin = 7 }
- assert_equal(7, @format_o.left_margin)
- assert_nothing_raised {
- ft = @format_o.format(GETTYSBURG).split("\n")
- assert_match(/^ {11}Four score/, ft[0])
- assert_match(/^ {7}November/, ft[-1])
- }
- end
-
- def test_hard_margins
- assert_nothing_raised { @format_o = Text::Format.new }
- assert(!@format_o.hard_margins)
- assert_nothing_raised {
- @format_o.hard_margins = true
- @format_o.columns = 5
- @format_o.first_indent = 0
- @format_o.format_style = Text::Format::RIGHT_FILL
- }
- assert(@format_o.hard_margins)
- assert_equal(FIVE_COL, @format_o.format(GETTYSBURG))
- assert_nothing_raised {
- @format_o.split_rules |= Text::Format::SPLIT_CONTINUATION
- assert_equal(Text::Format::SPLIT_CONTINUATION_FIXED,
- @format_o.split_rules)
- }
- assert_equal(FIVE_CNT, @format_o.format(GETTYSBURG))
- end
-
- # Tests both nobreak and nobreak_regex, since one is only useful
- # with the other.
- def test_nobreak
- assert_nothing_raised { @format_o = Text::Format.new }
- assert(!@format_o.nobreak)
- assert(@format_o.nobreak_regex.empty?)
- assert_nothing_raised {
- @format_o.nobreak = true
- @format_o.nobreak_regex = { '^this$' => '^continent$' }
- @format_o.columns = 77
- }
- assert(@format_o.nobreak)
- assert_equal({ '^this$' => '^continent$' }, @format_o.nobreak_regex)
- assert_match(/^this continent/,
- @format_o.format(GETTYSBURG).split("\n")[1])
- end
-
- def test_right_align?
- assert_nothing_raised { @format_o = Text::Format.new }
- assert(!@format_o.right_align?)
- assert_nothing_raised {
- @format_o.format_style = Text::Format::RIGHT_ALIGN
- }
- assert(@format_o.right_align?)
- assert_nothing_raised {
- @format_o.format_style = Text::Format::RIGHT_FILL
- }
- assert(!@format_o.right_align?)
- assert_nothing_raised { @format_o.format_style = Text::Format::JUSTIFY }
- assert(!@format_o.right_align?)
- # The format testing is done in test_format_style
- end
-
- def test_right_fill?
- assert_nothing_raised { @format_o = Text::Format.new }
- assert(!@format_o.right_fill?)
- assert_nothing_raised {
- @format_o.format_style = Text::Format::RIGHT_ALIGN
- }
- assert(!@format_o.right_fill?)
- assert_nothing_raised {
- @format_o.format_style = Text::Format::RIGHT_FILL
- }
- assert(@format_o.right_fill?)
- assert_nothing_raised {
- @format_o.format_style = Text::Format::JUSTIFY
- }
- assert(!@format_o.right_fill?)
- # The format testing is done in test_format_style
- end
-
- def test_right_margin
- assert_nothing_raised { @format_o = Text::Format.new }
- assert_equal(0, @format_o.right_margin)
- assert_nothing_raised { @format_o.right_margin = -3 }
- assert_equal(3, @format_o.right_margin)
- assert_nothing_raised { @format_o.right_margin = "9" }
- assert_equal(9, @format_o.right_margin)
- assert_nothing_raised { @format_o.right_margin = "-2" }
- assert_equal(2, @format_o.right_margin)
- assert_nothing_raised { @format_o.right_margin = 7 }
- assert_equal(7, @format_o.right_margin)
- assert_nothing_raised {
- ft = @format_o.format(GETTYSBURG).split("\n")
- assert_match(/^ {4}Four score.*forth on$/, ft[0])
- assert_match(/^November/, ft[-1])
- }
- end
-
- def test_tabstop
- assert_nothing_raised { @format_o = Text::Format.new }
- assert_equal(8, @format_o.tabstop)
- assert_nothing_raised { @format_o.tabstop = 7 }
- assert_equal(7, @format_o.tabstop)
- assert_nothing_raised { @format_o.tabstop = -3 }
- assert_equal(3, @format_o.tabstop)
- assert_nothing_raised { @format_o.tabstop = "9" }
- assert_equal(9, @format_o.tabstop)
- assert_nothing_raised { @format_o.tabstop = "-2" }
- assert_equal(2, @format_o.tabstop)
- end
-
- def test_text
- assert_nothing_raised { @format_o = Text::Format.new }
- assert_equal([], @format_o.text)
- assert_nothing_raised { @format_o.text = "Test Text" }
- assert_equal("Test Text", @format_o.text)
- assert_nothing_raised { @format_o.text = ["Line 1", "Line 2"] }
- assert_equal(["Line 1", "Line 2"], @format_o.text)
- end
-
- def test_s_new
- # new(NilClass) { block }
- assert_nothing_raised do
- @format_o = Text::Format.new {
- self.text = "Test 1, 2, 3"
- }
- end
- assert_equal("Test 1, 2, 3", @format_o.text)
-
- # new(Hash Symbols)
- assert_nothing_raised { @format_o = Text::Format.new(:columns => 72) }
- assert_equal(72, @format_o.columns)
-
- # new(Hash String)
- assert_nothing_raised { @format_o = Text::Format.new('columns' => 72) }
- assert_equal(72, @format_o.columns)
-
- # new(Hash) { block }
- assert_nothing_raised do
- @format_o = Text::Format.new('columns' => 80) {
- self.text = "Test 4, 5, 6"
- }
- end
- assert_equal("Test 4, 5, 6", @format_o.text)
- assert_equal(80, @format_o.columns)
-
- # new(Text::Format)
- assert_nothing_raised do
- fo = Text::Format.new(@format_o)
- assert(fo == @format_o)
- end
-
- # new(Text::Format) { block }
- assert_nothing_raised do
- fo = Text::Format.new(@format_o) { self.columns = 79 }
- assert(fo != @format_o)
- end
-
- # new(String)
- assert_nothing_raised { @format_o = Text::Format.new("Test A, B, C") }
- assert_equal("Test A, B, C", @format_o.text)
-
- # new(String) { block }
- assert_nothing_raised do
- @format_o = Text::Format.new("Test X, Y, Z") { self.columns = -5 }
- end
- assert_equal("Test X, Y, Z", @format_o.text)
- assert_equal(5, @format_o.columns)
- end
-
- def test_center
- assert_nothing_raised { @format_o = Text::Format.new }
- assert_nothing_raised do
- ct = @format_o.center(GETTYSBURG.split("\n")).split("\n")
- assert_match(/^ Four score and seven years ago our fathers brought forth on this/, ct[0])
- assert_match(/^ not perish from the earth./, ct[-3])
- end
- end
-
- def test_expand
- assert_nothing_raised { @format_o = Text::Format.new }
- assert_equal(" ", @format_o.expand("\t "))
- assert_nothing_raised { @format_o.tabstop = 4 }
- assert_equal(" ", @format_o.expand("\t "))
- end
-
- def test_unexpand
- assert_nothing_raised { @format_o = Text::Format.new }
- assert_equal("\t ", @format_o.unexpand(" "))
- assert_nothing_raised { @format_o.tabstop = 4 }
- assert_equal("\t ", @format_o.unexpand(" "))
- end
-
- def test_space_only
- assert_equal("", Text::Format.new.format(" "))
- assert_equal("", Text::Format.new.format("\n"))
- assert_equal("", Text::Format.new.format(" "))
- assert_equal("", Text::Format.new.format(" \n"))
- assert_equal("", Text::Format.new.paragraphs("\n"))
- assert_equal("", Text::Format.new.paragraphs(" "))
- assert_equal("", Text::Format.new.paragraphs(" "))
- assert_equal("", Text::Format.new.paragraphs(" \n"))
- assert_equal("", Text::Format.new.paragraphs(["\n"]))
- assert_equal("", Text::Format.new.paragraphs([" "]))
- assert_equal("", Text::Format.new.paragraphs([" "]))
- assert_equal("", Text::Format.new.paragraphs([" \n"]))
- end
-
- def test_splendiferous
- h = nil
- test = "This is a splendiferous test"
- assert_nothing_raised { @format_o = Text::Format.new(:columns => 6, :left_margin => 0, :indent => 0, :first_indent => 0) }
- assert_match(/^splendiferous$/, @format_o.format(test))
- assert_nothing_raised { @format_o.hard_margins = true }
- assert_match(/^lendif$/, @format_o.format(test))
- assert_nothing_raised { h = Object.new }
- assert_nothing_raised do
- @format_o.split_rules = Text::Format::SPLIT_HYPHENATION
- class << h #:nodoc:
- def hyphenate_to(word, size)
- return ["", word] if size < 2
- [word[0 ... size], word[size .. -1]]
- end
- end
- @format_o.hyphenator = h
- end
- assert_match(/^iferou$/, @format_o.format(test))
- assert_nothing_raised { h = Object.new }
- assert_nothing_raised do
- class << h #:nodoc:
- def hyphenate_to(word, size, formatter)
- return ["", word] if word.size < formatter.columns
- [word[0 ... size], word[size .. -1]]
- end
- end
- @format_o.hyphenator = h
- end
- assert_match(/^ferous$/, @format_o.format(test))
- end
- end
-end
diff --git a/actionmailer/lib/action_mailer/vendor/text_format.rb b/actionmailer/lib/action_mailer/vendor/text_format.rb
deleted file mode 100644
index c6c8c394d0..0000000000
--- a/actionmailer/lib/action_mailer/vendor/text_format.rb
+++ /dev/null
@@ -1,10 +0,0 @@
-# Prefer gems to the bundled libs.
-require 'rubygems'
-
-begin
- gem 'text-format', '>= 0.6.3'
-rescue Gem::LoadError
- $:.unshift "#{File.dirname(__FILE__)}/text-format-0.6.3"
-end
-
-require 'text/format'
diff --git a/actionmailer/test/abstract_unit.rb b/actionmailer/test/abstract_unit.rb
index 50b8a53006..ce09bb5d61 100644
--- a/actionmailer/test/abstract_unit.rb
+++ b/actionmailer/test/abstract_unit.rb
@@ -8,7 +8,6 @@ $:.unshift(lib) unless $:.include?('lib') || $:.include?(lib)
require 'rubygems'
require 'test/unit'
-
require 'action_mailer'
# Show backtraces for deprecated behavior for quicker cleanup.
@@ -18,14 +17,10 @@ ActiveSupport::Deprecation.debug = true
ActionView::Template.register_template_handler :haml, lambda { |template| "Look its HAML!".inspect }
ActionView::Template.register_template_handler :bak, lambda { |template| "Lame backup".inspect }
-ActionView::Base::DEFAULT_CONFIG = { :assets_dir => '/nowhere' }
-
-$:.unshift "#{File.dirname(__FILE__)}/fixtures/helpers"
+FIXTURE_LOAD_PATH = File.expand_path('fixtures', File.dirname(__FILE__))
+ActionMailer::Base.view_paths = FIXTURE_LOAD_PATH
-FIXTURE_LOAD_PATH = File.join(File.dirname(__FILE__), 'fixtures')
-ActionMailer::Base.template_root = FIXTURE_LOAD_PATH
-
-class MockSMTP
+class MockSMTP
def self.deliveries
@@deliveries
end
@@ -49,19 +44,11 @@ class Net::SMTP
end
end
-def uses_gem(gem_name, test_name, version = '> 0')
- gem gem_name.to_s, version
- require gem_name.to_s
- yield
-rescue LoadError
- $stderr.puts "Skipping #{test_name} tests. `gem install #{gem_name}` and try again."
-end
-
-def set_delivery_method(delivery_method)
+def set_delivery_method(method)
@old_delivery_method = ActionMailer::Base.delivery_method
- ActionMailer::Base.delivery_method = delivery_method
+ ActionMailer::Base.delivery_method = method
end
def restore_delivery_method
ActionMailer::Base.delivery_method = @old_delivery_method
-end
+end \ No newline at end of file
diff --git a/actionmailer/test/base_test.rb b/actionmailer/test/base_test.rb
new file mode 100644
index 0000000000..03e3f81acd
--- /dev/null
+++ b/actionmailer/test/base_test.rb
@@ -0,0 +1,488 @@
+# encoding: utf-8
+require 'abstract_unit'
+
+class BaseTest < ActiveSupport::TestCase
+ class BaseMailer < ActionMailer::Base
+ self.mailer_name = "base_mailer"
+
+ default :to => 'system@test.lindsaar.net',
+ :from => 'jose@test.plataformatec.com',
+ :reply_to => 'mikel@test.lindsaar.net'
+
+ def welcome(hash = {})
+ headers['X-SPAM'] = "Not SPAM"
+ mail({:subject => "The first email on new API!"}.merge!(hash))
+ end
+
+ def simple(hash = {})
+ mail(hash)
+ end
+
+ def html_only(hash = {})
+ mail(hash)
+ end
+
+ def plain_text_only(hash = {})
+ mail(hash)
+ end
+
+ def simple_with_headers(hash = {})
+ headers hash
+ mail
+ end
+
+ def attachment_with_content(hash = {})
+ attachments['invoice.pdf'] = 'This is test File content'
+ mail(hash)
+ end
+
+ def attachment_with_hash
+ attachments['invoice.jpg'] = { :data => "you smiling", :mime_type => "image/x-jpg",
+ :transfer_encoding => "base64" }
+ mail
+ end
+
+ def implicit_multipart(hash = {})
+ attachments['invoice.pdf'] = 'This is test File content' if hash.delete(:attachments)
+ mail(hash)
+ end
+
+ def implicit_with_locale(hash = {})
+ mail(hash)
+ end
+
+ def explicit_multipart(hash = {})
+ attachments['invoice.pdf'] = 'This is test File content' if hash.delete(:attachments)
+ mail(hash) do |format|
+ format.text { render :text => "TEXT Explicit Multipart" }
+ format.html { render :text => "HTML Explicit Multipart" }
+ end
+ end
+
+ def explicit_multipart_templates(hash = {})
+ mail(hash) do |format|
+ format.html
+ format.text
+ end
+ end
+
+ def explicit_multipart_with_any(hash = {})
+ mail(hash) do |format|
+ format.any(:text, :html){ render :text => "Format with any!" }
+ end
+ end
+
+ def custom_block(include_html=false)
+ mail do |format|
+ format.text(:content_transfer_encoding => "base64"){ render "welcome" }
+ format.html{ render "welcome" } if include_html
+ end
+ end
+ end
+
+ test "method call to mail does not raise error" do
+ assert_nothing_raised { BaseMailer.welcome }
+ end
+
+ # Basic mail usage without block
+ test "mail() should set the headers of the mail message" do
+ email = BaseMailer.welcome
+ assert_equal(['system@test.lindsaar.net'], email.to)
+ assert_equal(['jose@test.plataformatec.com'], email.from)
+ assert_equal('The first email on new API!', email.subject)
+ end
+
+ test "mail() with from overwrites the class level default" do
+ email = BaseMailer.welcome(:from => 'someone@example.com',
+ :to => 'another@example.org')
+ assert_equal(['someone@example.com'], email.from)
+ assert_equal(['another@example.org'], email.to)
+ end
+
+ test "mail() with bcc, cc, content_type, charset, mime_version, reply_to and date" do
+ @time = Time.now.beginning_of_day.to_datetime
+ email = BaseMailer.welcome(:bcc => 'bcc@test.lindsaar.net',
+ :cc => 'cc@test.lindsaar.net',
+ :content_type => 'multipart/mixed',
+ :charset => 'iso-8559-1',
+ :mime_version => '2.0',
+ :reply_to => 'reply-to@test.lindsaar.net',
+ :date => @time)
+ assert_equal(['bcc@test.lindsaar.net'], email.bcc)
+ assert_equal(['cc@test.lindsaar.net'], email.cc)
+ assert_equal('multipart/mixed', email.content_type)
+ assert_equal('iso-8559-1', email.charset)
+ assert_equal('2.0', email.mime_version)
+ assert_equal(['reply-to@test.lindsaar.net'], email.reply_to)
+ assert_equal(@time, email.date)
+ end
+
+ test "mail() renders the template using the method being processed" do
+ email = BaseMailer.welcome
+ assert_equal("Welcome", email.body.encoded)
+ end
+
+ test "can pass in :body to the mail method hash" do
+ email = BaseMailer.welcome(:body => "Hello there")
+ assert_equal("text/plain", email.mime_type)
+ assert_equal("Hello there", email.body.encoded)
+ end
+
+ # Custom headers
+ test "custom headers" do
+ email = BaseMailer.welcome
+ assert_equal("Not SPAM", email['X-SPAM'].decoded)
+ end
+
+ test "can pass random headers in as a hash to mail" do
+ hash = {'X-Special-Domain-Specific-Header' => "SecretValue",
+ 'In-Reply-To' => '1234@mikel.me.com' }
+ mail = BaseMailer.simple(hash)
+ assert_equal('SecretValue', mail['X-Special-Domain-Specific-Header'].decoded)
+ assert_equal('1234@mikel.me.com', mail['In-Reply-To'].decoded)
+ end
+
+ test "can pass random headers in as a hash" do
+ hash = {'X-Special-Domain-Specific-Header' => "SecretValue",
+ 'In-Reply-To' => '1234@mikel.me.com' }
+ mail = BaseMailer.simple_with_headers(hash)
+ assert_equal('SecretValue', mail['X-Special-Domain-Specific-Header'].decoded)
+ assert_equal('1234@mikel.me.com', mail['In-Reply-To'].decoded)
+ end
+
+ # Attachments
+ test "attachment with content" do
+ email = BaseMailer.attachment_with_content
+ assert_equal(1, email.attachments.length)
+ assert_equal('invoice.pdf', email.attachments[0].filename)
+ assert_equal('This is test File content', email.attachments['invoice.pdf'].decoded)
+ end
+
+ test "attachment gets content type from filename" do
+ email = BaseMailer.attachment_with_content
+ assert_equal('invoice.pdf', email.attachments[0].filename)
+ end
+
+ test "attachment with hash" do
+ email = BaseMailer.attachment_with_hash
+ assert_equal(1, email.attachments.length)
+ assert_equal('invoice.jpg', email.attachments[0].filename)
+ expected = "\312\213\254\232)b"
+ expected.force_encoding(Encoding::BINARY) if '1.9'.respond_to?(:force_encoding)
+ assert_equal expected, email.attachments['invoice.jpg'].decoded
+ end
+
+ test "sets mime type to multipart/mixed when attachment is included" do
+ email = BaseMailer.attachment_with_content
+ assert_equal(1, email.attachments.length)
+ assert_equal("multipart/mixed", email.mime_type)
+ end
+
+ test "adds the rendered template as part" do
+ email = BaseMailer.attachment_with_content
+ assert_equal(2, email.parts.length)
+ assert_equal("multipart/mixed", email.mime_type)
+ assert_equal("text/html", email.parts[0].mime_type)
+ assert_equal("Attachment with content", email.parts[0].body.encoded)
+ assert_equal("application/pdf", email.parts[1].mime_type)
+ assert_equal("VGhpcyBpcyB0ZXN0IEZpbGUgY29udGVudA==\r\n", email.parts[1].body.encoded)
+ end
+
+ test "adds the given :body as part" do
+ email = BaseMailer.attachment_with_content(:body => "I'm the eggman")
+ assert_equal(2, email.parts.length)
+ assert_equal("multipart/mixed", email.mime_type)
+ assert_equal("text/plain", email.parts[0].mime_type)
+ assert_equal("I'm the eggman", email.parts[0].body.encoded)
+ assert_equal("application/pdf", email.parts[1].mime_type)
+ assert_equal("VGhpcyBpcyB0ZXN0IEZpbGUgY29udGVudA==\r\n", email.parts[1].body.encoded)
+ end
+
+ # Defaults values
+ test "uses default charset from class" do
+ with_default BaseMailer, :charset => "US-ASCII" do
+ email = BaseMailer.welcome
+ assert_equal("US-ASCII", email.charset)
+
+ email = BaseMailer.welcome(:charset => "iso-8559-1")
+ assert_equal("iso-8559-1", email.charset)
+ end
+ end
+
+ test "uses default content type from class" do
+ with_default BaseMailer, :content_type => "text/html" do
+ email = BaseMailer.welcome
+ assert_equal("text/html", email.mime_type)
+
+ email = BaseMailer.welcome(:content_type => "text/plain")
+ assert_equal("text/plain", email.mime_type)
+ end
+ end
+
+ test "uses default mime version from class" do
+ with_default BaseMailer, :mime_version => "2.0" do
+ email = BaseMailer.welcome
+ assert_equal("2.0", email.mime_version)
+
+ email = BaseMailer.welcome(:mime_version => "1.0")
+ assert_equal("1.0", email.mime_version)
+ end
+ end
+
+ test "uses random default headers from class" do
+ with_default BaseMailer, "X-SPAM" => "Not spam" do
+ email = BaseMailer.simple
+ assert_equal("Not spam", email["X-SPAM"].decoded)
+ end
+ end
+
+ test "subject gets default from I18n" do
+ BaseMailer.default[:subject] = nil
+ email = BaseMailer.welcome(:subject => nil)
+ assert_equal "Welcome", email.subject
+
+ I18n.backend.store_translations('en', :actionmailer => {:base_mailer => {:welcome => {:subject => "New Subject!"}}})
+ email = BaseMailer.welcome(:subject => nil)
+ assert_equal "New Subject!", email.subject
+ end
+
+ # Implicit multipart
+ test "implicit multipart" do
+ email = BaseMailer.implicit_multipart
+ assert_equal(2, email.parts.size)
+ assert_equal("multipart/alternative", email.mime_type)
+ assert_equal("text/plain", email.parts[0].mime_type)
+ assert_equal("TEXT Implicit Multipart", email.parts[0].body.encoded)
+ assert_equal("text/html", email.parts[1].mime_type)
+ assert_equal("HTML Implicit Multipart", email.parts[1].body.encoded)
+ end
+
+ test "implicit multipart with sort order" do
+ order = ["text/html", "text/plain"]
+ with_default BaseMailer, :parts_order => order do
+ email = BaseMailer.implicit_multipart
+ assert_equal("text/html", email.parts[0].mime_type)
+ assert_equal("text/plain", email.parts[1].mime_type)
+
+ email = BaseMailer.implicit_multipart(:parts_order => order.reverse)
+ assert_equal("text/plain", email.parts[0].mime_type)
+ assert_equal("text/html", email.parts[1].mime_type)
+ end
+ end
+
+ test "implicit multipart with attachments creates nested parts" do
+ email = BaseMailer.implicit_multipart(:attachments => true)
+ assert_equal("application/pdf", email.parts[0].mime_type)
+ assert_equal("multipart/alternative", email.parts[1].mime_type)
+ assert_equal("text/plain", email.parts[1].parts[0].mime_type)
+ assert_equal("TEXT Implicit Multipart", email.parts[1].parts[0].body.encoded)
+ assert_equal("text/html", email.parts[1].parts[1].mime_type)
+ assert_equal("HTML Implicit Multipart", email.parts[1].parts[1].body.encoded)
+ end
+
+ test "implicit multipart with attachments and sort order" do
+ order = ["text/html", "text/plain"]
+ with_default BaseMailer, :parts_order => order do
+ email = BaseMailer.implicit_multipart(:attachments => true)
+ assert_equal("application/pdf", email.parts[0].mime_type)
+ assert_equal("multipart/alternative", email.parts[1].mime_type)
+ assert_equal("text/plain", email.parts[1].parts[1].mime_type)
+ assert_equal("text/html", email.parts[1].parts[0].mime_type)
+ end
+ end
+
+ test "implicit multipart with default locale" do
+ email = BaseMailer.implicit_with_locale
+ assert_equal(2, email.parts.size)
+ assert_equal("multipart/alternative", email.mime_type)
+ assert_equal("text/plain", email.parts[0].mime_type)
+ assert_equal("Implicit with locale TEXT", email.parts[0].body.encoded)
+ assert_equal("text/html", email.parts[1].mime_type)
+ assert_equal("Implicit with locale EN HTML", email.parts[1].body.encoded)
+ end
+
+ test "implicit multipart with other locale" do
+ swap I18n, :locale => :pl do
+ email = BaseMailer.implicit_with_locale
+ assert_equal(2, email.parts.size)
+ assert_equal("multipart/alternative", email.mime_type)
+ assert_equal("text/plain", email.parts[0].mime_type)
+ assert_equal("Implicit with locale PL TEXT", email.parts[0].body.encoded)
+ assert_equal("text/html", email.parts[1].mime_type)
+ assert_equal("Implicit with locale HTML", email.parts[1].body.encoded)
+ end
+ end
+
+ test "implicit multipart with several view paths uses the first one with template" do
+ begin
+ BaseMailer.view_paths.unshift(File.join(FIXTURE_LOAD_PATH, "another.path"))
+ email = BaseMailer.welcome
+ assert_equal("Welcome from another path", email.body.encoded)
+ ensure
+ BaseMailer.view_paths.shift
+ end
+ end
+
+ test "implicit multipart with inexistent templates uses the next view path" do
+ begin
+ BaseMailer.view_paths.unshift(File.join(FIXTURE_LOAD_PATH, "unknown"))
+ email = BaseMailer.welcome
+ assert_equal("Welcome", email.body.encoded)
+ ensure
+ BaseMailer.view_paths.shift
+ end
+ end
+
+ # Explicit multipart
+ test "explicit multipart" do
+ email = BaseMailer.explicit_multipart
+ assert_equal(2, email.parts.size)
+ assert_equal("multipart/alternative", email.mime_type)
+ assert_equal("text/plain", email.parts[0].mime_type)
+ assert_equal("TEXT Explicit Multipart", email.parts[0].body.encoded)
+ assert_equal("text/html", email.parts[1].mime_type)
+ assert_equal("HTML Explicit Multipart", email.parts[1].body.encoded)
+ end
+
+ test "explicit multipart does not sort order" do
+ order = ["text/html", "text/plain"]
+ with_default BaseMailer, :parts_order => order do
+ email = BaseMailer.explicit_multipart
+ assert_equal("text/plain", email.parts[0].mime_type)
+ assert_equal("text/html", email.parts[1].mime_type)
+
+ email = BaseMailer.explicit_multipart(:parts_order => order.reverse)
+ assert_equal("text/plain", email.parts[0].mime_type)
+ assert_equal("text/html", email.parts[1].mime_type)
+ end
+ end
+
+ test "explicit multipart with attachments creates nested parts" do
+ email = BaseMailer.explicit_multipart(:attachments => true)
+ assert_equal("application/pdf", email.parts[0].mime_type)
+ assert_equal("multipart/alternative", email.parts[1].mime_type)
+ assert_equal("text/plain", email.parts[1].parts[0].mime_type)
+ assert_equal("TEXT Explicit Multipart", email.parts[1].parts[0].body.encoded)
+ assert_equal("text/html", email.parts[1].parts[1].mime_type)
+ assert_equal("HTML Explicit Multipart", email.parts[1].parts[1].body.encoded)
+ end
+
+ test "explicit multipart with templates" do
+ email = BaseMailer.explicit_multipart_templates
+ assert_equal(2, email.parts.size)
+ assert_equal("multipart/alternative", email.mime_type)
+ assert_equal("text/html", email.parts[0].mime_type)
+ assert_equal("HTML Explicit Multipart Templates", email.parts[0].body.encoded)
+ assert_equal("text/plain", email.parts[1].mime_type)
+ assert_equal("TEXT Explicit Multipart Templates", email.parts[1].body.encoded)
+ end
+
+ test "explicit multipart with any" do
+ email = BaseMailer.explicit_multipart_with_any
+ assert_equal(2, email.parts.size)
+ assert_equal("multipart/alternative", email.mime_type)
+ assert_equal("text/plain", email.parts[0].mime_type)
+ assert_equal("Format with any!", email.parts[0].body.encoded)
+ assert_equal("text/html", email.parts[1].mime_type)
+ assert_equal("Format with any!", email.parts[1].body.encoded)
+ end
+
+ test "explicit multipart with options" do
+ email = BaseMailer.custom_block(true)
+ email.ready_to_send!
+ assert_equal(2, email.parts.size)
+ assert_equal("multipart/alternative", email.mime_type)
+ assert_equal("text/plain", email.parts[0].mime_type)
+ assert_equal("base64", email.parts[0].content_transfer_encoding)
+ assert_equal("text/html", email.parts[1].mime_type)
+ assert_equal("7bit", email.parts[1].content_transfer_encoding)
+ end
+
+ test "explicit multipart with one part is rendered as body" do
+ email = BaseMailer.custom_block
+ assert_equal(0, email.parts.size)
+ assert_equal("text/plain", email.mime_type)
+ assert_equal("base64", email.content_transfer_encoding)
+ end
+
+ # Class level API with method missing
+ test "should respond to action methods" do
+ assert BaseMailer.respond_to?(:welcome)
+ assert BaseMailer.respond_to?(:implicit_multipart)
+ assert !BaseMailer.respond_to?(:mail)
+ assert !BaseMailer.respond_to?(:headers)
+ end
+
+ test "calling just the action should return the generated mail object" do
+ BaseMailer.deliveries.clear
+ email = BaseMailer.welcome
+ assert_equal(0, BaseMailer.deliveries.length)
+ assert_equal('The first email on new API!', email.subject)
+ end
+
+ test "calling deliver on the action should deliver the mail object" do
+ BaseMailer.deliveries.clear
+ BaseMailer.expects(:deliver_mail).once
+ mail = BaseMailer.welcome.deliver
+ assert_instance_of Mail::Message, mail
+ end
+
+ test "calling deliver on the action should increment the deliveries collection" do
+ BaseMailer.deliveries.clear
+ BaseMailer.welcome.deliver
+ assert_equal(1, BaseMailer.deliveries.length)
+ end
+
+ test "calling deliver, ActionMailer should yield back to mail to let it call :do_delivery on itself" do
+ mail = Mail::Message.new
+ mail.expects(:do_delivery).once
+ BaseMailer.expects(:welcome).returns(mail)
+ BaseMailer.welcome.deliver
+ end
+
+ test "explicit multipart should be multipart" do
+ mail = BaseMailer.explicit_multipart
+ assert_not_nil(mail.content_type_parameters[:boundary])
+ end
+
+ test "should set a content type if only has an html part" do
+ mail = BaseMailer.html_only
+ assert_equal('text/html', mail.mime_type)
+ end
+
+ test "should set a content type if only has an plain text part" do
+ mail = BaseMailer.plain_text_only
+ assert_equal('text/plain', mail.mime_type)
+ end
+
+ protected
+
+ # Execute the block setting the given values and restoring old values after
+ # the block is executed.
+ def swap(klass, new_values)
+ old_values = {}
+ new_values.each do |key, value|
+ old_values[key] = klass.send key
+ klass.send :"#{key}=", value
+ end
+ yield
+ ensure
+ old_values.each do |key, value|
+ klass.send :"#{key}=", value
+ end
+ end
+
+ def with_default(klass, new_values)
+ hash = klass.default
+ old_values = {}
+ new_values.each do |key, value|
+ old_values[key] = hash[key]
+ hash[key] = value
+ end
+ yield
+ ensure
+ old_values.each do |key, value|
+ hash[key] = value
+ end
+ end
+end
diff --git a/actionmailer/test/delivery_method_test.rb b/actionmailer/test/delivery_method_test.rb
deleted file mode 100644
index 8f8c6b0275..0000000000
--- a/actionmailer/test/delivery_method_test.rb
+++ /dev/null
@@ -1,101 +0,0 @@
-require 'abstract_unit'
-
-class DefaultDeliveryMethodMailer < ActionMailer::Base
-end
-
-class NonDefaultDeliveryMethodMailer < ActionMailer::Base
- self.delivery_method = :sendmail
-end
-
-class FileDeliveryMethodMailer < ActionMailer::Base
- self.delivery_method = :file
-end
-
-class CustomDeliveryMethod
- attr_accessor :custom_deliveries
- def initialize()
- @customer_deliveries = []
- end
-
- def self.perform_delivery(mail)
- self.custom_deliveries << mail
- end
-end
-
-class CustomerDeliveryMailer < ActionMailer::Base
- self.delivery_method = CustomDeliveryMethod.new
-end
-
-class ActionMailerBase_delivery_method_Test < Test::Unit::TestCase
- def setup
- set_delivery_method :smtp
- end
-
- def teardown
- restore_delivery_method
- end
-
- def test_should_be_the_default_smtp
- assert_instance_of ActionMailer::DeliveryMethod::Smtp, ActionMailer::Base.delivery_method
- end
-end
-
-class DefaultDeliveryMethodMailer_delivery_method_Test < Test::Unit::TestCase
- def setup
- set_delivery_method :smtp
- end
-
- def teardown
- restore_delivery_method
- end
-
- def test_should_be_the_default_smtp
- assert_instance_of ActionMailer::DeliveryMethod::Smtp, DefaultDeliveryMethodMailer.delivery_method
- end
-end
-
-class NonDefaultDeliveryMethodMailer_delivery_method_Test < Test::Unit::TestCase
- def setup
- set_delivery_method :smtp
- end
-
- def teardown
- restore_delivery_method
- end
-
- def test_should_be_the_set_delivery_method
- assert_instance_of ActionMailer::DeliveryMethod::Sendmail, NonDefaultDeliveryMethodMailer.delivery_method
- end
-end
-
-class FileDeliveryMethodMailer_delivery_method_Test < Test::Unit::TestCase
- def setup
- set_delivery_method :smtp
- end
-
- def teardown
- restore_delivery_method
- end
-
- def test_should_be_the_set_delivery_method
- assert_instance_of ActionMailer::DeliveryMethod::File, FileDeliveryMethodMailer.delivery_method
- end
-
- def test_should_default_location_to_the_tmpdir
- assert_equal "#{Dir.tmpdir}/mails", ActionMailer::Base.file_settings[:location]
- end
-end
-
-class CustomDeliveryMethodMailer_delivery_method_Test < Test::Unit::TestCase
- def setup
- set_delivery_method :smtp
- end
-
- def teardown
- restore_delivery_method
- end
-
- def test_should_be_the_set_delivery_method
- assert_instance_of CustomDeliveryMethod, CustomerDeliveryMailer.delivery_method
- end
-end
diff --git a/actionmailer/test/delivery_methods_test.rb b/actionmailer/test/delivery_methods_test.rb
new file mode 100644
index 0000000000..4907ca0903
--- /dev/null
+++ b/actionmailer/test/delivery_methods_test.rb
@@ -0,0 +1,170 @@
+require 'abstract_unit'
+require 'mail'
+
+class MyCustomDelivery
+end
+
+class BogusDelivery
+ def initialize(*)
+ end
+
+ def deliver!(mail)
+ raise "failed"
+ end
+end
+
+class DefaultsDeliveryMethodsTest < ActiveSupport::TestCase
+ test "default smtp settings" do
+ settings = { :address => "localhost",
+ :port => 25,
+ :domain => 'localhost.localdomain',
+ :user_name => nil,
+ :password => nil,
+ :authentication => nil,
+ :enable_starttls_auto => true }
+ assert_equal settings, ActionMailer::Base.smtp_settings
+ end
+
+ test "default file delivery settings" do
+ settings = {:location => "#{Dir.tmpdir}/mails"}
+ assert_equal settings, ActionMailer::Base.file_settings
+ end
+
+ test "default sendmail settings" do
+ settings = {:location => '/usr/sbin/sendmail',
+ :arguments => '-i -t'}
+ assert_equal settings, ActionMailer::Base.sendmail_settings
+ end
+end
+
+class CustomDeliveryMethodsTest < ActiveSupport::TestCase
+ def setup
+ @old_delivery_method = ActionMailer::Base.delivery_method
+ ActionMailer::Base.add_delivery_method :custom, MyCustomDelivery
+ end
+
+ def teardown
+ ActionMailer::Base.delivery_method = @old_delivery_method
+ ActionMailer::Base.delivery_methods.delete(:custom)
+ end
+
+ test "allow to add custom delivery method" do
+ ActionMailer::Base.delivery_method = :custom
+ assert_equal :custom, ActionMailer::Base.delivery_method
+ end
+
+ test "allow to customize custom settings" do
+ ActionMailer::Base.custom_settings = { :foo => :bar }
+ assert_equal Hash[:foo => :bar], ActionMailer::Base.custom_settings
+ end
+
+ test "respond to custom settings" do
+ assert_respond_to ActionMailer::Base, :custom_settings
+ assert_respond_to ActionMailer::Base, :custom_settings=
+ end
+
+ test "does not respond to unknown settings" do
+ assert_raise NoMethodError do
+ ActionMailer::Base.another_settings
+ end
+ end
+end
+
+class MailDeliveryTest < ActiveSupport::TestCase
+ class DeliveryMailer < ActionMailer::Base
+ DEFAULT_HEADERS = {
+ :to => 'mikel@test.lindsaar.net',
+ :from => 'jose@test.plataformatec.com'
+ }
+
+ def welcome(hash={})
+ mail(DEFAULT_HEADERS.merge(hash))
+ end
+ end
+
+ def setup
+ ActionMailer::Base.delivery_method = :smtp
+ end
+
+ def teardown
+ DeliveryMailer.delivery_method = :smtp
+ DeliveryMailer.perform_deliveries = true
+ DeliveryMailer.raise_delivery_errors = true
+ end
+
+ test "ActionMailer should be told when Mail gets delivered" do
+ DeliveryMailer.deliveries.clear
+ DeliveryMailer.expects(:deliver_mail).once
+ DeliveryMailer.welcome.deliver
+ end
+
+ test "delivery method can be customized per instance" do
+ email = DeliveryMailer.welcome.deliver
+ assert_instance_of Mail::SMTP, email.delivery_method
+ email = DeliveryMailer.welcome(:delivery_method => :test).deliver
+ assert_instance_of Mail::TestMailer, email.delivery_method
+ end
+
+ test "delivery method can be customized in subclasses not changing the parent" do
+ DeliveryMailer.delivery_method = :test
+ assert_equal :smtp, ActionMailer::Base.delivery_method
+ $BREAK = true
+ email = DeliveryMailer.welcome.deliver
+ assert_instance_of Mail::TestMailer, email.delivery_method
+ end
+
+ test "non registered delivery methods raises errors" do
+ DeliveryMailer.delivery_method = :unknown
+ assert_raise RuntimeError do
+ DeliveryMailer.welcome.deliver
+ end
+ end
+
+ test "does not perform deliveries if requested" do
+ DeliveryMailer.perform_deliveries = false
+ DeliveryMailer.deliveries.clear
+ Mail::Message.any_instance.expects(:deliver!).never
+ DeliveryMailer.welcome.deliver
+ end
+
+ test "does not append the deliveries collection if told not to perform the delivery" do
+ DeliveryMailer.perform_deliveries = false
+ DeliveryMailer.deliveries.clear
+ DeliveryMailer.welcome.deliver
+ assert_equal(0, DeliveryMailer.deliveries.length)
+ end
+
+ test "raise errors on bogus deliveries" do
+ DeliveryMailer.delivery_method = BogusDelivery
+ DeliveryMailer.deliveries.clear
+ assert_raise RuntimeError do
+ DeliveryMailer.welcome.deliver
+ end
+ end
+
+ test "does not increment the deliveries collection on error" do
+ DeliveryMailer.delivery_method = BogusDelivery
+ DeliveryMailer.deliveries.clear
+ assert_raise RuntimeError do
+ DeliveryMailer.welcome.deliver
+ end
+ assert_equal(0, DeliveryMailer.deliveries.length)
+ end
+
+ test "does not raise errors on bogus deliveries if set" do
+ DeliveryMailer.delivery_method = BogusDelivery
+ DeliveryMailer.raise_delivery_errors = false
+ assert_nothing_raised do
+ DeliveryMailer.welcome.deliver
+ end
+ end
+
+ test "does not increment the deliveries collection on bogus deliveries" do
+ DeliveryMailer.delivery_method = BogusDelivery
+ DeliveryMailer.raise_delivery_errors = false
+ DeliveryMailer.deliveries.clear
+ DeliveryMailer.welcome.deliver
+ assert_equal(0, DeliveryMailer.deliveries.length)
+ end
+
+end \ No newline at end of file
diff --git a/actionmailer/test/fixtures/another.path/base_mailer/welcome.erb b/actionmailer/test/fixtures/another.path/base_mailer/welcome.erb
new file mode 100644
index 0000000000..ef451298e2
--- /dev/null
+++ b/actionmailer/test/fixtures/another.path/base_mailer/welcome.erb
@@ -0,0 +1 @@
+Welcome from another path \ No newline at end of file
diff --git a/actionmailer/test/fixtures/base_mailer/attachment_with_content.erb b/actionmailer/test/fixtures/base_mailer/attachment_with_content.erb
new file mode 100644
index 0000000000..deb9dbd03b
--- /dev/null
+++ b/actionmailer/test/fixtures/base_mailer/attachment_with_content.erb
@@ -0,0 +1 @@
+Attachment with content \ No newline at end of file
diff --git a/actionmailer/test/fixtures/base_mailer/explicit_multipart_templates.html.erb b/actionmailer/test/fixtures/base_mailer/explicit_multipart_templates.html.erb
new file mode 100644
index 0000000000..c0a61b6249
--- /dev/null
+++ b/actionmailer/test/fixtures/base_mailer/explicit_multipart_templates.html.erb
@@ -0,0 +1 @@
+HTML Explicit Multipart Templates \ No newline at end of file
diff --git a/actionmailer/test/fixtures/base_mailer/explicit_multipart_templates.text.erb b/actionmailer/test/fixtures/base_mailer/explicit_multipart_templates.text.erb
new file mode 100644
index 0000000000..507230b1de
--- /dev/null
+++ b/actionmailer/test/fixtures/base_mailer/explicit_multipart_templates.text.erb
@@ -0,0 +1 @@
+TEXT Explicit Multipart Templates \ No newline at end of file
diff --git a/actionmailer/test/fixtures/base_mailer/html_only.html.erb b/actionmailer/test/fixtures/base_mailer/html_only.html.erb
new file mode 100644
index 0000000000..9c99a008e7
--- /dev/null
+++ b/actionmailer/test/fixtures/base_mailer/html_only.html.erb
@@ -0,0 +1 @@
+<h1>Testing</h1> \ No newline at end of file
diff --git a/actionmailer/test/fixtures/base_mailer/implicit_multipart.html.erb b/actionmailer/test/fixtures/base_mailer/implicit_multipart.html.erb
new file mode 100644
index 0000000000..23745cd282
--- /dev/null
+++ b/actionmailer/test/fixtures/base_mailer/implicit_multipart.html.erb
@@ -0,0 +1 @@
+HTML Implicit Multipart \ No newline at end of file
diff --git a/actionmailer/test/fixtures/base_mailer/implicit_multipart.text.erb b/actionmailer/test/fixtures/base_mailer/implicit_multipart.text.erb
new file mode 100644
index 0000000000..d51437fc72
--- /dev/null
+++ b/actionmailer/test/fixtures/base_mailer/implicit_multipart.text.erb
@@ -0,0 +1 @@
+TEXT Implicit Multipart \ No newline at end of file
diff --git a/actionmailer/test/fixtures/base_mailer/implicit_with_locale.en.html.erb b/actionmailer/test/fixtures/base_mailer/implicit_with_locale.en.html.erb
new file mode 100644
index 0000000000..34e39c8fdb
--- /dev/null
+++ b/actionmailer/test/fixtures/base_mailer/implicit_with_locale.en.html.erb
@@ -0,0 +1 @@
+Implicit with locale EN HTML \ No newline at end of file
diff --git a/actionmailer/test/fixtures/base_mailer/implicit_with_locale.html.erb b/actionmailer/test/fixtures/base_mailer/implicit_with_locale.html.erb
new file mode 100644
index 0000000000..5ce283f221
--- /dev/null
+++ b/actionmailer/test/fixtures/base_mailer/implicit_with_locale.html.erb
@@ -0,0 +1 @@
+Implicit with locale HTML \ No newline at end of file
diff --git a/actionmailer/test/fixtures/base_mailer/implicit_with_locale.pl.text.erb b/actionmailer/test/fixtures/base_mailer/implicit_with_locale.pl.text.erb
new file mode 100644
index 0000000000..c49cbae60a
--- /dev/null
+++ b/actionmailer/test/fixtures/base_mailer/implicit_with_locale.pl.text.erb
@@ -0,0 +1 @@
+Implicit with locale PL TEXT \ No newline at end of file
diff --git a/actionmailer/test/fixtures/base_mailer/implicit_with_locale.text.erb b/actionmailer/test/fixtures/base_mailer/implicit_with_locale.text.erb
new file mode 100644
index 0000000000..5a18ff62cd
--- /dev/null
+++ b/actionmailer/test/fixtures/base_mailer/implicit_with_locale.text.erb
@@ -0,0 +1 @@
+Implicit with locale TEXT \ No newline at end of file
diff --git a/actionmailer/test/fixtures/base_mailer/plain_text_only.text.erb b/actionmailer/test/fixtures/base_mailer/plain_text_only.text.erb
new file mode 100644
index 0000000000..0a90125685
--- /dev/null
+++ b/actionmailer/test/fixtures/base_mailer/plain_text_only.text.erb
@@ -0,0 +1 @@
+Testing \ No newline at end of file
diff --git a/actionmailer/test/fixtures/base_mailer/welcome.erb b/actionmailer/test/fixtures/base_mailer/welcome.erb
new file mode 100644
index 0000000000..01f3f00c63
--- /dev/null
+++ b/actionmailer/test/fixtures/base_mailer/welcome.erb
@@ -0,0 +1 @@
+Welcome \ No newline at end of file
diff --git a/actionmailer/test/fixtures/helper_mailer/use_example_helper.erb b/actionmailer/test/fixtures/helper_mailer/use_example_helper.erb
deleted file mode 100644
index fcff3bb1b4..0000000000
--- a/actionmailer/test/fixtures/helper_mailer/use_example_helper.erb
+++ /dev/null
@@ -1 +0,0 @@
-So, <%= example_format(@text) %>
diff --git a/actionmailer/test/fixtures/helper_mailer/use_helper.erb b/actionmailer/test/fixtures/helper_mailer/use_helper.erb
deleted file mode 100644
index 378777f8bb..0000000000
--- a/actionmailer/test/fixtures/helper_mailer/use_helper.erb
+++ /dev/null
@@ -1 +0,0 @@
-Hello, <%= person_name %>. Thanks for registering!
diff --git a/actionmailer/test/fixtures/helper_mailer/use_helper_method.erb b/actionmailer/test/fixtures/helper_mailer/use_helper_method.erb
deleted file mode 100644
index d5b8b285e7..0000000000
--- a/actionmailer/test/fixtures/helper_mailer/use_helper_method.erb
+++ /dev/null
@@ -1 +0,0 @@
-This message brought to you by <%= name_of_the_mailer_class %>.
diff --git a/actionmailer/test/fixtures/helper_mailer/use_mail_helper.erb b/actionmailer/test/fixtures/helper_mailer/use_mail_helper.erb
deleted file mode 100644
index 96ec49d18a..0000000000
--- a/actionmailer/test/fixtures/helper_mailer/use_mail_helper.erb
+++ /dev/null
@@ -1,5 +0,0 @@
-From "Romeo and Juliet":
-
-<%= block_format @text %>
-
-Good ol' Shakespeare.
diff --git a/actionmailer/test/fixtures/helpers/example_helper.rb b/actionmailer/test/fixtures/helpers/example_helper.rb
deleted file mode 100644
index f6a6a49ced..0000000000
--- a/actionmailer/test/fixtures/helpers/example_helper.rb
+++ /dev/null
@@ -1,5 +0,0 @@
-module ExampleHelper
- def example_format(text)
- "<em><strong><small>#{h(text)}</small></strong></em>".html_safe!
- end
-end
diff --git a/actionmailer/test/fixtures/nested_layout_mailer/signup.html.erb b/actionmailer/test/fixtures/nested_layout_mailer/signup.html.erb
new file mode 100644
index 0000000000..4789e888c6
--- /dev/null
+++ b/actionmailer/test/fixtures/nested_layout_mailer/signup.html.erb
@@ -0,0 +1 @@
+We do not spam \ No newline at end of file
diff --git a/actionmailer/test/fixtures/test_mailer/body_ivar.erb b/actionmailer/test/fixtures/test_mailer/body_ivar.erb
deleted file mode 100644
index 1421e5c908..0000000000
--- a/actionmailer/test/fixtures/test_mailer/body_ivar.erb
+++ /dev/null
@@ -1,2 +0,0 @@
-body: <%= @body %>
-bar: <%= @bar %> \ No newline at end of file
diff --git a/actionmailer/test/fixtures/test_mailer/multipart_alternative.html.erb b/actionmailer/test/fixtures/test_mailer/multipart_alternative.html.erb
new file mode 100644
index 0000000000..73ea14f82f
--- /dev/null
+++ b/actionmailer/test/fixtures/test_mailer/multipart_alternative.html.erb
@@ -0,0 +1 @@
+<strong>foo</strong> <%= @foo %> \ No newline at end of file
diff --git a/actionmailer/test/fixtures/test_mailer/multipart_alternative.plain.erb b/actionmailer/test/fixtures/test_mailer/multipart_alternative.plain.erb
new file mode 100644
index 0000000000..779fe4c1ea
--- /dev/null
+++ b/actionmailer/test/fixtures/test_mailer/multipart_alternative.plain.erb
@@ -0,0 +1 @@
+foo: <%= @foo %> \ No newline at end of file
diff --git a/actionmailer/test/mail_helper_test.rb b/actionmailer/test/mail_helper_test.rb
index 2d3565d159..7cc0804323 100644
--- a/actionmailer/test/mail_helper_test.rb
+++ b/actionmailer/test/mail_helper_test.rb
@@ -1,96 +1,54 @@
require 'abstract_unit'
-module MailerHelper
- def person_name
- "Mr. Joe Person"
- end
-end
-
class HelperMailer < ActionMailer::Base
- helper MailerHelper
- helper :example
-
- def use_helper(recipient)
- recipients recipient
- subject "using helpers"
- from "tester@example.com"
- end
-
- def use_example_helper(recipient)
- recipients recipient
- subject "using helpers"
- from "tester@example.com"
-
- @text = "emphasize me!"
- end
-
- def use_mail_helper(recipient)
- recipients recipient
- subject "using mailing helpers"
- from "tester@example.com"
-
+ def use_mail_helper
@text = "But soft! What light through yonder window breaks? It is the east, " +
"and Juliet is the sun. Arise, fair sun, and kill the envious moon, " +
"which is sick and pale with grief that thou, her maid, art far more " +
"fair than she. Be not her maid, for she is envious! Her vestal " +
"livery is but sick and green, and none but fools do wear it. Cast " +
"it off!"
- end
- def use_helper_method(recipient)
- recipients recipient
- subject "using helpers"
- from "tester@example.com"
-
- @text = "emphasize me!"
+ mail_with_defaults do |format|
+ format.html { render(:inline => "<%= block_format @text %>") }
+ end
end
- private
-
- def name_of_the_mailer_class
- self.class.name
+ def use_mailer
+ mail_with_defaults do |format|
+ format.html { render(:inline => "<%= mailer.message.subject %>") }
end
- helper_method :name_of_the_mailer_class
-end
+ end
-class MailerHelperTest < Test::Unit::TestCase
- def new_mail( charset="utf-8" )
- mail = Mail.new
- mail.set_content_type "text", "plain", { "charset" => charset } if charset
- mail
+ def use_message
+ mail_with_defaults do |format|
+ format.html { render(:inline => "<%= message.subject %>") }
+ end
end
- def setup
- set_delivery_method :test
- ActionMailer::Base.perform_deliveries = true
- ActionMailer::Base.deliveries = []
+ protected
- @recipient = 'test@localhost'
- end
-
- def teardown
- restore_delivery_method
- end
-
- def test_use_helper
- mail = HelperMailer.create_use_helper(@recipient)
- assert_match %r{Mr. Joe Person}, mail.encoded
+ def mail_with_defaults(&block)
+ mail(:to => "test@localhost", :from => "tester@example.com",
+ :subject => "using helpers", &block)
end
+end
- def test_use_example_helper
- mail = HelperMailer.create_use_example_helper(@recipient)
- assert_match %r{<em><strong><small>emphasize me!}, mail.encoded
+class MailerHelperTest < ActionMailer::TestCase
+ def test_use_mail_helper
+ mail = HelperMailer.use_mail_helper
+ assert_match %r{ But soft!}, mail.body.encoded
+ assert_match %r{east, and\r\n Juliet}, mail.body.encoded
end
- def test_use_helper_method
- mail = HelperMailer.create_use_helper_method(@recipient)
- assert_match %r{HelperMailer}, mail.encoded
+ def test_use_mailer
+ mail = HelperMailer.use_mailer
+ assert_match "using helpers", mail.body.encoded
end
- def test_use_mail_helper
- mail = HelperMailer.create_use_mail_helper(@recipient)
- assert_match %r{ But soft!}, mail.encoded
- assert_match %r{east, and\r\n Juliet}, mail.encoded
+ def test_use_message
+ mail = HelperMailer.use_message
+ assert_match "using helpers", mail.body.encoded
end
end
diff --git a/actionmailer/test/mail_test.rb b/actionmailer/test/mail_test.rb
deleted file mode 100644
index ea6f25d157..0000000000
--- a/actionmailer/test/mail_test.rb
+++ /dev/null
@@ -1,24 +0,0 @@
-require 'abstract_unit'
-
-class MailTest < Test::Unit::TestCase
- def test_body
- m = Mail.new
- expected = 'something_with_underscores'
- m.content_transfer_encoding = 'quoted-printable'
- quoted_body = [expected].pack('*M')
- m.body = quoted_body
- assert_equal "something_with_underscores=\r\n", m.body.encoded
- # CHANGED: body returns object, not string, Changed m.body to m.body.to_s
- assert_equal expected, m.body.to_s
- end
-
- def test_nested_attachments_are_recognized_correctly
- fixture = File.read("#{File.dirname(__FILE__)}/fixtures/raw_email_with_nested_attachment")
- mail = Mail.new(fixture)
- assert_equal 2, mail.attachments.length
- assert_equal "image/png", mail.attachments.first.mime_type
- assert_equal 1902, mail.attachments.first.decoded.length
- assert_equal "application/pkcs7-signature", mail.attachments.last.mime_type
- end
-
-end
diff --git a/actionmailer/test/adv_attr_test.rb b/actionmailer/test/old_base/adv_attr_test.rb
index f22d733bc5..f22d733bc5 100644
--- a/actionmailer/test/adv_attr_test.rb
+++ b/actionmailer/test/old_base/adv_attr_test.rb
diff --git a/actionmailer/test/asset_host_test.rb b/actionmailer/test/old_base/asset_host_test.rb
index f3383e5608..124032f1d9 100644
--- a/actionmailer/test/asset_host_test.rb
+++ b/actionmailer/test/old_base/asset_host_test.rb
@@ -1,8 +1,8 @@
require 'abstract_unit'
class AssetHostMailer < ActionMailer::Base
- def email_with_asset(recipient)
- recipients recipient
+ def email_with_asset
+ recipients 'test@localhost'
subject "testing email containing asset path while asset_host is set"
from "tester@example.com"
end
@@ -12,9 +12,7 @@ class AssetHostTest < Test::Unit::TestCase
def setup
set_delivery_method :test
ActionMailer::Base.perform_deliveries = true
- ActionMailer::Base.deliveries = []
-
- @recipient = 'test@localhost'
+ ActionMailer::Base.deliveries.clear
end
def teardown
@@ -23,7 +21,7 @@ class AssetHostTest < Test::Unit::TestCase
def test_asset_host_as_string
ActionController::Base.asset_host = "http://www.example.com"
- mail = AssetHostMailer.deliver_email_with_asset(@recipient)
+ mail = AssetHostMailer.email_with_asset
assert_equal "<img alt=\"Somelogo\" src=\"http://www.example.com/images/somelogo.png\" />", mail.body.to_s.strip
end
@@ -35,7 +33,7 @@ class AssetHostTest < Test::Unit::TestCase
"http://assets.example.com"
end
}
- mail = AssetHostMailer.deliver_email_with_asset(@recipient)
+ mail = AssetHostMailer.email_with_asset
assert_equal "<img alt=\"Somelogo\" src=\"http://images.example.com/images/somelogo.png\" />", mail.body.to_s.strip
end
@@ -48,7 +46,7 @@ class AssetHostTest < Test::Unit::TestCase
end
}
mail = nil
- assert_nothing_raised { mail = AssetHostMailer.deliver_email_with_asset(@recipient) }
+ assert_nothing_raised { mail = AssetHostMailer.email_with_asset }
assert_equal "<img alt=\"Somelogo\" src=\"http://www.example.com/images/somelogo.png\" />", mail.body.to_s.strip
end
end \ No newline at end of file
diff --git a/actionmailer/test/mail_layout_test.rb b/actionmailer/test/old_base/mail_layout_test.rb
index 0877e7b2cb..5679aa5a64 100644
--- a/actionmailer/test/mail_layout_test.rb
+++ b/actionmailer/test/old_base/mail_layout_test.rb
@@ -1,32 +1,33 @@
require 'abstract_unit'
class AutoLayoutMailer < ActionMailer::Base
- def hello(recipient)
- recipients recipient
+
+ def hello
+ recipients 'test@localhost'
subject "You have a mail"
from "tester@example.com"
end
- def spam(recipient)
- recipients recipient
+ def spam
+ recipients 'test@localhost'
subject "You have a mail"
from "tester@example.com"
@world = "Earth"
- render(:inline => "Hello, <%= @world %>", :layout => 'spam')
+ body render(:inline => "Hello, <%= @world %>", :layout => 'spam')
end
- def nolayout(recipient)
- recipients recipient
+ def nolayout
+ recipients 'test@localhost'
subject "You have a mail"
from "tester@example.com"
@world = "Earth"
- render(:inline => "Hello, <%= @world %>", :layout => false)
+ body render(:inline => "Hello, <%= @world %>", :layout => false)
end
- def multipart(recipient, type = nil)
- recipients recipient
+ def multipart(type = nil)
+ recipients 'test@localhost'
subject "You have a mail"
from "tester@example.com"
@@ -37,14 +38,14 @@ end
class ExplicitLayoutMailer < ActionMailer::Base
layout 'spam', :except => [:logout]
- def signup(recipient)
- recipients recipient
+ def signup
+ recipients 'test@localhost'
subject "You have a mail"
from "tester@example.com"
end
- def logout(recipient)
- recipients recipient
+ def logout
+ recipients 'test@localhost'
subject "You have a mail"
from "tester@example.com"
end
@@ -54,9 +55,7 @@ class LayoutMailerTest < Test::Unit::TestCase
def setup
set_delivery_method :test
ActionMailer::Base.perform_deliveries = true
- ActionMailer::Base.deliveries = []
-
- @recipient = 'test@localhost'
+ ActionMailer::Base.deliveries.clear
end
def teardown
@@ -64,12 +63,12 @@ class LayoutMailerTest < Test::Unit::TestCase
end
def test_should_pickup_default_layout
- mail = AutoLayoutMailer.create_hello(@recipient)
+ mail = AutoLayoutMailer.hello
assert_equal "Hello from layout Inside", mail.body.to_s.strip
end
def test_should_pickup_multipart_layout
- mail = AutoLayoutMailer.create_multipart(@recipient)
+ mail = AutoLayoutMailer.multipart
# CHANGED: content_type returns an object
# assert_equal "multipart/alternative", mail.content_type
assert_equal "multipart/alternative", mail.mime_type
@@ -78,7 +77,7 @@ class LayoutMailerTest < Test::Unit::TestCase
# CHANGED: content_type returns an object
# assert_equal 'text/plain', mail.parts.first.content_type
assert_equal 'text/plain', mail.parts.first.mime_type
-
+
# CHANGED: body returns an object
# assert_equal "text/plain layout - text/plain multipart", mail.parts.first.body
assert_equal "text/plain layout - text/plain multipart", mail.parts.first.body.to_s
@@ -93,7 +92,7 @@ class LayoutMailerTest < Test::Unit::TestCase
end
def test_should_pickup_multipartmixed_layout
- mail = AutoLayoutMailer.create_multipart(@recipient, "multipart/mixed")
+ mail = AutoLayoutMailer.multipart("multipart/mixed")
# CHANGED: content_type returns an object
# assert_equal "multipart/mixed", mail.content_type
assert_equal "multipart/mixed", mail.mime_type
@@ -115,7 +114,7 @@ class LayoutMailerTest < Test::Unit::TestCase
end
def test_should_fix_multipart_layout
- mail = AutoLayoutMailer.create_multipart(@recipient, "text/plain")
+ mail = AutoLayoutMailer.multipart("text/plain")
assert_equal "multipart/alternative", mail.mime_type
assert_equal 2, mail.parts.size
@@ -128,22 +127,22 @@ class LayoutMailerTest < Test::Unit::TestCase
def test_should_pickup_layout_given_to_render
- mail = AutoLayoutMailer.create_spam(@recipient)
+ mail = AutoLayoutMailer.spam
assert_equal "Spammer layout Hello, Earth", mail.body.to_s.strip
end
def test_should_respect_layout_false
- mail = AutoLayoutMailer.create_nolayout(@recipient)
+ mail = AutoLayoutMailer.nolayout
assert_equal "Hello, Earth", mail.body.to_s.strip
end
def test_explicit_class_layout
- mail = ExplicitLayoutMailer.create_signup(@recipient)
+ mail = ExplicitLayoutMailer.signup
assert_equal "Spammer layout We do not spam", mail.body.to_s.strip
end
def test_explicit_layout_exceptions
- mail = ExplicitLayoutMailer.create_logout(@recipient)
+ mail = ExplicitLayoutMailer.logout
assert_equal "You logged out", mail.body.to_s.strip
end
end
diff --git a/actionmailer/test/mail_render_test.rb b/actionmailer/test/old_base/mail_render_test.rb
index 09ce5e4854..405d43d7d3 100644
--- a/actionmailer/test/mail_render_test.rb
+++ b/actionmailer/test/old_base/mail_render_test.rb
@@ -1,60 +1,43 @@
require 'abstract_unit'
class RenderMailer < ActionMailer::Base
- def inline_template(recipient)
- recipients recipient
+ def inline_template
+ recipients 'test@localhost'
subject "using helpers"
from "tester@example.com"
@world = "Earth"
- render :inline => "Hello, <%= @world %>"
+ body render(:inline => "Hello, <%= @world %>")
end
- def file_template(recipient)
- recipients recipient
+ def file_template
+ recipients 'test@localhost'
subject "using helpers"
from "tester@example.com"
- @recipient = recipient
- render :file => "templates/signed_up"
- end
-
- def implicit_body(recipient)
- recipients recipient
- subject "using helpers"
- from "tester@example.com"
-
- @recipient = recipient
- render :template => "templates/signed_up"
+ @recipient = 'test@localhost'
+ body render(:file => "templates/signed_up")
end
- def rxml_template(recipient)
- recipients recipient
+ def rxml_template
+ recipients 'test@localhost'
subject "rendering rxml template"
from "tester@example.com"
end
- def included_subtemplate(recipient)
- recipients recipient
+ def included_subtemplate
+ recipients 'test@localhost'
subject "Including another template in the one being rendered"
from "tester@example.com"
end
- def mailer_accessor(recipient)
- recipients recipient
- subject "Mailer Accessor"
- from "tester@example.com"
-
- render :inline => "Look, <%= mailer.subject %>!"
- end
-
- def no_instance_variable(recipient)
- recipients recipient
+ def no_instance_variable
+ recipients 'test@localhost'
subject "No Instance Variable"
from "tester@example.com"
silence_warnings do
- render :inline => "Look, subject.nil? is <%= @subject.nil? %>!"
+ body render(:inline => "Look, subject.nil? is <%= @subject.nil? %>!")
end
end
@@ -62,19 +45,46 @@ class RenderMailer < ActionMailer::Base
super
mailer_name "test_mailer"
end
+
+ def multipart_alternative
+ recipients 'test@localhost'
+ subject 'multipart/alternative'
+ from 'tester@example.com'
+
+ build_multipart_message(:foo => "bar")
+ end
+
+ private
+ def build_multipart_message(assigns = {})
+ content_type "multipart/alternative"
+
+ part "text/plain" do |p|
+ p.body = build_body_part('plain', assigns, :layout => false)
+ end
+
+ part "text/html" do |p|
+ p.body = build_body_part('html', assigns)
+ end
+ end
+
+ def build_body_part(content_type, assigns, options = {})
+ ActiveSupport::Deprecation.silence do
+ render "#{template}.#{content_type}", :body => assigns
+ end
+ end
end
class FirstMailer < ActionMailer::Base
- def share(recipient)
- recipients recipient
+ def share
+ recipients 'test@localhost'
subject "using helpers"
from "tester@example.com"
end
end
class SecondMailer < ActionMailer::Base
- def share(recipient)
- recipients recipient
+ def share
+ recipients 'test@localhost'
subject "using helpers"
from "tester@example.com"
end
@@ -86,7 +96,7 @@ class RenderHelperTest < Test::Unit::TestCase
def setup
set_delivery_method :test
ActionMailer::Base.perform_deliveries = true
- ActionMailer::Base.deliveries = []
+ ActionMailer::Base.deliveries.clear
@recipient = 'test@localhost'
end
@@ -95,47 +105,47 @@ class RenderHelperTest < Test::Unit::TestCase
restore_delivery_method
end
- def test_implicit_body
- mail = RenderMailer.create_implicit_body(@recipient)
- assert_equal "Hello there, \n\nMr. test@localhost", mail.body.to_s.strip
- end
-
def test_inline_template
- mail = RenderMailer.create_inline_template(@recipient)
+ mail = RenderMailer.inline_template
assert_equal "Hello, Earth", mail.body.to_s.strip
end
def test_file_template
- mail = RenderMailer.create_file_template(@recipient)
+ mail = RenderMailer.file_template
assert_equal "Hello there, \n\nMr. test@localhost", mail.body.to_s.strip
end
def test_rxml_template
- mail = RenderMailer.deliver_rxml_template(@recipient)
+ mail = RenderMailer.rxml_template.deliver
assert_equal "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<test/>", mail.body.to_s.strip
end
def test_included_subtemplate
- mail = RenderMailer.deliver_included_subtemplate(@recipient)
+ mail = RenderMailer.included_subtemplate.deliver
assert_equal "Hey Ho, let's go!", mail.body.to_s.strip
end
- def test_mailer_accessor
- mail = RenderMailer.deliver_mailer_accessor(@recipient)
- assert_equal "Look, Mailer Accessor!", mail.body.to_s.strip
- end
-
def test_no_instance_variable
- mail = RenderMailer.deliver_no_instance_variable(@recipient)
+ mail = RenderMailer.no_instance_variable.deliver
assert_equal "Look, subject.nil? is true!", mail.body.to_s.strip
end
+
+ def test_legacy_multipart_alternative
+ mail = RenderMailer.multipart_alternative.deliver
+ assert_equal(2, mail.parts.size)
+ assert_equal("multipart/alternative", mail.mime_type)
+ assert_equal("text/plain", mail.parts[0].mime_type)
+ assert_equal("foo: bar", mail.parts[0].body.encoded)
+ assert_equal("text/html", mail.parts[1].mime_type)
+ assert_equal("<strong>foo</strong> bar", mail.parts[1].body.encoded)
+ end
end
class FirstSecondHelperTest < Test::Unit::TestCase
def setup
set_delivery_method :test
ActionMailer::Base.perform_deliveries = true
- ActionMailer::Base.deliveries = []
+ ActionMailer::Base.deliveries.clear
@recipient = 'test@localhost'
end
@@ -145,13 +155,13 @@ class FirstSecondHelperTest < Test::Unit::TestCase
end
def test_ordering
- mail = FirstMailer.create_share(@recipient)
+ mail = FirstMailer.share
assert_equal "first mail", mail.body.to_s.strip
- mail = SecondMailer.create_share(@recipient)
+ mail = SecondMailer.share
assert_equal "second mail", mail.body.to_s.strip
- mail = FirstMailer.create_share(@recipient)
+ mail = FirstMailer.share
assert_equal "first mail", mail.body.to_s.strip
- mail = SecondMailer.create_share(@recipient)
+ mail = SecondMailer.share
assert_equal "second mail", mail.body.to_s.strip
end
end
diff --git a/actionmailer/test/mail_service_test.rb b/actionmailer/test/old_base/mail_service_test.rb
index f87d9b2e5b..70dafaf33c 100644
--- a/actionmailer/test/mail_service_test.rb
+++ b/actionmailer/test/old_base/mail_service_test.rb
@@ -2,7 +2,7 @@
require 'abstract_unit'
class FunkyPathMailer < ActionMailer::Base
- self.template_root = "#{File.dirname(__FILE__)}/fixtures/path.with.dots"
+ self.view_paths = "#{File.dirname(__FILE__)}/../fixtures/path.with.dots"
def multipart_with_template_path_with_dots(recipient)
recipients recipient
@@ -27,20 +27,19 @@ class TestMailer < ActionMailer::Base
subject "[Cancelled] Goodbye #{recipient}"
from "system@loudthinking.com"
sent_on Time.local(2004, 12, 12)
-
- render :text => "Goodbye, Mr. #{recipient}"
+ body "Goodbye, Mr. #{recipient}"
end
def from_with_name
from "System <system@loudthinking.com>"
recipients "root@loudthinking.com"
- render :text => "Nothing to see here."
+ body "Nothing to see here."
end
def from_without_name
from "system@loudthinking.com"
recipients "root@loudthinking.com"
- render :text => "Nothing to see here."
+ body "Nothing to see here."
end
def cc_bcc(recipient)
@@ -51,7 +50,7 @@ class TestMailer < ActionMailer::Base
cc "nobody@loudthinking.com"
bcc "root@loudthinking.com"
- render :text => "Nothing to see here."
+ body "Nothing to see here."
end
def different_reply_to(recipient)
@@ -61,7 +60,7 @@ class TestMailer < ActionMailer::Base
sent_on Time.local(2008, 5, 23)
reply_to "atraver@gmail.com"
- render :text => "Nothing to see here."
+ body "Nothing to see here."
end
def iso_charset(recipient)
@@ -73,7 +72,7 @@ class TestMailer < ActionMailer::Base
bcc "root@loudthinking.com"
charset "iso-8859-1"
- render :text => "Nothing to see here."
+ body "Nothing to see here."
end
def unencoded_subject(recipient)
@@ -84,7 +83,7 @@ class TestMailer < ActionMailer::Base
cc "nobody@loudthinking.com"
bcc "root@loudthinking.com"
- render :text => "Nothing to see here."
+ body "Nothing to see here."
end
def extended_headers(recipient)
@@ -96,7 +95,7 @@ class TestMailer < ActionMailer::Base
bcc "Grytøyr <stian3@example.net>"
charset "iso-8859-1"
- render :text => "Nothing to see here."
+ body "Nothing to see here."
end
def utf8_body(recipient)
@@ -108,7 +107,7 @@ class TestMailer < ActionMailer::Base
bcc "Foo áëô îü <extended@example.net>"
charset "utf-8"
- render :text => "åœö blah"
+ body "åœö blah"
end
def multipart_with_mime_version(recipient)
@@ -120,11 +119,11 @@ class TestMailer < ActionMailer::Base
content_type "multipart/alternative"
part "text/plain" do |p|
- p.body = render_message(:text => "blah")
+ p.body = render(:text => "blah")
end
part "text/html" do |p|
- p.body = render_message(:inline => "<%= content_tag(:b, 'blah') %>")
+ p.body = render(:inline => "<%= content_tag(:b, 'blah') %>")
end
end
@@ -158,7 +157,7 @@ class TestMailer < ActionMailer::Base
attachment :content_type => "image/jpeg", :filename => File.join(File.dirname(__FILE__), "fixtures", "attachments", "foo.jpg"),
:data => "123456789"
- render :text => "plain text default"
+ body "plain text default"
end
def implicitly_multipart_example(recipient, cs = nil, order = nil)
@@ -187,12 +186,12 @@ class TestMailer < ActionMailer::Base
from "test@example.com"
content_type "text/html"
- render :text => "<em>Emphasize</em> <strong>this</strong>"
+ body "<em>Emphasize</em> <strong>this</strong>"
end
def html_mail_with_underscores(recipient)
subject "html mail with underscores"
- render :text => %{<a href="http://google.com" target="_blank">_Google</a>}
+ body %{<a href="http://google.com" target="_blank">_Google</a>}
end
def custom_template(recipient)
@@ -219,7 +218,7 @@ class TestMailer < ActionMailer::Base
subject "various newlines"
from "test@example.com"
- render :text => "line #1\nline #2\rline #3\r\nline #4\r\r" +
+ body "line #1\nline #2\rline #3\r\nline #4\r\r" +
"line #5\n\nline#6\r\n\r\nline #7"
end
@@ -282,7 +281,7 @@ class TestMailer < ActionMailer::Base
from "One: Two <test@example.com>"
cc "Three: Four <test@example.com>"
bcc "Five: Six <test@example.com>"
- render :text => "testing"
+ body "testing"
end
def custom_content_type_attributes
@@ -290,28 +289,21 @@ class TestMailer < ActionMailer::Base
subject "custom content types"
from "some.one@somewhere.test"
content_type "text/plain; format=flowed"
- render :text => "testing"
+ body "testing"
end
def return_path
recipients "no.one@nowhere.test"
subject "return path test"
from "some.one@somewhere.test"
- headers "return-path" => "another@somewhere.test"
- render :text => "testing"
- end
-
- def body_ivar(recipient)
- recipients recipient
- subject "Body as a local variable"
- from "test@example.com"
- body :body => "foo", :bar => "baz"
+ headers["return-path"] = "another@somewhere.test"
+ body "testing"
end
def subject_with_i18n(recipient)
recipients recipient
from "system@loudthinking.com"
- render :text => "testing"
+ body "testing"
end
class << self
@@ -344,7 +336,7 @@ class ActionMailerTest < Test::Unit::TestCase
set_delivery_method :test
ActionMailer::Base.perform_deliveries = true
ActionMailer::Base.raise_delivery_errors = true
- ActionMailer::Base.deliveries = []
+ ActionMailer::Base.deliveries.clear
@original_logger = TestMailer.logger
@recipient = 'test@localhost'
@@ -357,7 +349,7 @@ class ActionMailerTest < Test::Unit::TestCase
def test_nested_parts
created = nil
- assert_nothing_raised { created = TestMailer.create_nested_multipart(@recipient)}
+ assert_nothing_raised { created = TestMailer.nested_multipart(@recipient)}
assert_equal 2, created.parts.size
assert_equal 2, created.parts.first.parts.size
@@ -373,8 +365,8 @@ class ActionMailerTest < Test::Unit::TestCase
def test_nested_parts_with_body
created = nil
- TestMailer.create_nested_multipart_with_body(@recipient)
- assert_nothing_raised { created = TestMailer.create_nested_multipart_with_body(@recipient)}
+ TestMailer.nested_multipart_with_body(@recipient)
+ assert_nothing_raised { created = TestMailer.nested_multipart_with_body(@recipient)}
assert_equal 1,created.parts.size
assert_equal 2,created.parts.first.parts.size
@@ -389,11 +381,13 @@ class ActionMailerTest < Test::Unit::TestCase
def test_attachment_with_custom_header
created = nil
- assert_nothing_raised { created = TestMailer.create_attachment_with_custom_header(@recipient) }
+ assert_nothing_raised { created = TestMailer.attachment_with_custom_header(@recipient) }
assert created.parts.any? { |p| p.header['content-id'].to_s == "<test@test.com>" }
end
def test_signed_up
+ TestMailer.delivery_method = :test
+
Time.stubs(:now => Time.now)
expected = new_mail
@@ -404,7 +398,7 @@ class ActionMailerTest < Test::Unit::TestCase
expected.date = Time.now
created = nil
- assert_nothing_raised { created = TestMailer.create_signed_up(@recipient) }
+ assert_nothing_raised { created = TestMailer.signed_up(@recipient) }
assert_not_nil created
expected.message_id = '<123@456>'
@@ -412,7 +406,7 @@ class ActionMailerTest < Test::Unit::TestCase
assert_equal expected.encoded, created.encoded
- assert_nothing_raised { TestMailer.deliver_signed_up(@recipient) }
+ assert_nothing_raised { TestMailer.signed_up(@recipient).deliver }
delivered = ActionMailer::Base.deliveries.first
assert_not_nil delivered
@@ -423,15 +417,6 @@ class ActionMailerTest < Test::Unit::TestCase
assert_equal expected.encoded, delivered.encoded
end
- def test_subject_with_i18n
- assert_nothing_raised { TestMailer.deliver_subject_with_i18n(@recipient) }
- assert_equal "Subject with i18n", ActionMailer::Base.deliveries.first.subject.to_s
-
- I18n.backend.store_translations('en', :actionmailer => {:test_mailer => {:subject_with_i18n => {:subject => "New Subject!"}}})
- assert_nothing_raised { TestMailer.deliver_subject_with_i18n(@recipient) }
- assert_equal "New Subject!", ActionMailer::Base.deliveries.last.subject.to_s
- end
-
def test_custom_template
expected = new_mail
expected.to = @recipient
@@ -441,7 +426,7 @@ class ActionMailerTest < Test::Unit::TestCase
expected.date = Time.local(2004, 12, 12)
created = nil
- assert_nothing_raised { created = TestMailer.create_custom_template(@recipient) }
+ assert_nothing_raised { created = TestMailer.custom_template(@recipient) }
assert_not_nil created
expected.message_id = '<123@456>'
created.message_id = '<123@456>'
@@ -464,7 +449,7 @@ class ActionMailerTest < Test::Unit::TestCase
# Now that the template is registered, there should be one part. The text/plain part.
created = nil
- assert_nothing_raised { created = TestMailer.create_custom_templating_extension(@recipient) }
+ assert_nothing_raised { created = TestMailer.custom_templating_extension(@recipient) }
assert_not_nil created
assert_equal 2, created.parts.length
assert_equal 'text/plain', created.parts[0].mime_type
@@ -480,13 +465,13 @@ class ActionMailerTest < Test::Unit::TestCase
expected.date = Time.local(2004, 12, 12)
created = nil
- assert_nothing_raised { created = TestMailer.create_cancelled_account(@recipient) }
+ assert_nothing_raised { created = TestMailer.cancelled_account(@recipient) }
assert_not_nil created
expected.message_id = '<123@456>'
created.message_id = '<123@456>'
assert_equal expected.encoded, created.encoded
- assert_nothing_raised { TestMailer.deliver_cancelled_account(@recipient) }
+ assert_nothing_raised { TestMailer.cancelled_account(@recipient).deliver }
assert_not_nil ActionMailer::Base.deliveries.first
delivered = ActionMailer::Base.deliveries.first
expected.message_id = '<123@456>'
@@ -507,7 +492,7 @@ class ActionMailerTest < Test::Unit::TestCase
created = nil
assert_nothing_raised do
- created = TestMailer.create_cc_bcc @recipient
+ created = TestMailer.cc_bcc @recipient
end
assert_not_nil created
expected.message_id = '<123@456>'
@@ -515,7 +500,7 @@ class ActionMailerTest < Test::Unit::TestCase
assert_equal expected.encoded, created.encoded
assert_nothing_raised do
- TestMailer.deliver_cc_bcc @recipient
+ TestMailer.cc_bcc(@recipient).deliver
end
assert_not_nil ActionMailer::Base.deliveries.first
@@ -527,8 +512,8 @@ class ActionMailerTest < Test::Unit::TestCase
end
def test_from_without_name_for_smtp
- ActionMailer::Base.delivery_method = :smtp
- TestMailer.deliver_from_without_name
+ TestMailer.delivery_method = :smtp
+ TestMailer.from_without_name.deliver
mail = MockSMTP.deliveries.first
assert_not_nil mail
@@ -538,17 +523,19 @@ class ActionMailerTest < Test::Unit::TestCase
end
def test_from_with_name_for_smtp
- ActionMailer::Base.delivery_method = :smtp
- TestMailer.deliver_from_with_name
+ TestMailer.delivery_method = :smtp
+ TestMailer.from_with_name.deliver
mail = MockSMTP.deliveries.first
assert_not_nil mail
mail, from, to = mail
- assert_equal 'system@loudthinking.com', from.addresses.first
+ assert_equal 'system@loudthinking.com', from
end
def test_reply_to
+ TestMailer.delivery_method = :test
+
expected = new_mail
expected.to = @recipient
@@ -560,7 +547,7 @@ class ActionMailerTest < Test::Unit::TestCase
created = nil
assert_nothing_raised do
- created = TestMailer.create_different_reply_to @recipient
+ created = TestMailer.different_reply_to @recipient
end
assert_not_nil created
@@ -570,7 +557,7 @@ class ActionMailerTest < Test::Unit::TestCase
assert_equal expected.encoded, created.encoded
assert_nothing_raised do
- TestMailer.deliver_different_reply_to @recipient
+ TestMailer.different_reply_to(@recipient).deliver
end
delivered = ActionMailer::Base.deliveries.first
@@ -583,6 +570,8 @@ class ActionMailerTest < Test::Unit::TestCase
end
def test_iso_charset
+ TestMailer.delivery_method = :test
+
expected = new_mail( "iso-8859-1" )
expected.to = @recipient
expected.subject = encode "testing isø charsets", "iso-8859-1"
@@ -594,7 +583,7 @@ class ActionMailerTest < Test::Unit::TestCase
created = nil
assert_nothing_raised do
- created = TestMailer.create_iso_charset @recipient
+ created = TestMailer.iso_charset @recipient
end
assert_not_nil created
@@ -604,7 +593,7 @@ class ActionMailerTest < Test::Unit::TestCase
assert_equal expected.encoded, created.encoded
assert_nothing_raised do
- TestMailer.deliver_iso_charset @recipient
+ TestMailer.iso_charset(@recipient).deliver
end
delivered = ActionMailer::Base.deliveries.first
@@ -617,6 +606,7 @@ class ActionMailerTest < Test::Unit::TestCase
end
def test_unencoded_subject
+ TestMailer.delivery_method = :test
expected = new_mail
expected.to = @recipient
expected.subject = "testing unencoded subject"
@@ -628,7 +618,7 @@ class ActionMailerTest < Test::Unit::TestCase
created = nil
assert_nothing_raised do
- created = TestMailer.create_unencoded_subject @recipient
+ created = TestMailer.unencoded_subject @recipient
end
assert_not_nil created
@@ -638,7 +628,7 @@ class ActionMailerTest < Test::Unit::TestCase
assert_equal expected.encoded, created.encoded
assert_nothing_raised do
- TestMailer.deliver_unencoded_subject @recipient
+ TestMailer.unencoded_subject(@recipient).deliver
end
delivered = ActionMailer::Base.deliveries.first
@@ -650,41 +640,33 @@ class ActionMailerTest < Test::Unit::TestCase
assert_equal expected.encoded, delivered.encoded
end
- def test_instances_are_nil
- assert_nil ActionMailer::Base.new
- assert_nil TestMailer.new
- end
-
def test_deliveries_array
assert_not_nil ActionMailer::Base.deliveries
assert_equal 0, ActionMailer::Base.deliveries.size
- TestMailer.deliver_signed_up(@recipient)
+ TestMailer.signed_up(@recipient).deliver
assert_equal 1, ActionMailer::Base.deliveries.size
assert_not_nil ActionMailer::Base.deliveries.first
end
def test_perform_deliveries_flag
ActionMailer::Base.perform_deliveries = false
- TestMailer.deliver_signed_up(@recipient)
+ TestMailer.signed_up(@recipient).deliver
assert_equal 0, ActionMailer::Base.deliveries.size
ActionMailer::Base.perform_deliveries = true
- TestMailer.deliver_signed_up(@recipient)
+ TestMailer.signed_up(@recipient).deliver
assert_equal 1, ActionMailer::Base.deliveries.size
end
def test_doesnt_raise_errors_when_raise_delivery_errors_is_false
ActionMailer::Base.raise_delivery_errors = false
- TestMailer.delivery_method.expects(:perform_delivery).raises(Exception)
- assert_nothing_raised { TestMailer.deliver_signed_up(@recipient) }
+ Mail::TestMailer.any_instance.expects(:deliver!).raises(Exception)
+ assert_nothing_raised { TestMailer.signed_up(@recipient).deliver }
end
def test_performs_delivery_via_sendmail
- sm = mock()
- sm.expects(:print).with(anything)
- sm.expects(:flush)
- IO.expects(:popen).once.with('/usr/sbin/sendmail -i -t', 'w+').yields(sm)
- ActionMailer::Base.delivery_method = :sendmail
- TestMailer.deliver_signed_up(@recipient)
+ IO.expects(:popen).once.with('/usr/sbin/sendmail -i -t -f "system@loudthinking.com" test@localhost', 'w+')
+ TestMailer.delivery_method = :sendmail
+ TestMailer.signed_up(@recipient).deliver
end
def test_unquote_quoted_printable_subject
@@ -769,7 +751,7 @@ EOF
created = nil
assert_nothing_raised do
- created = TestMailer.create_extended_headers @recipient
+ created = TestMailer.extended_headers @recipient
end
assert_not_nil created
@@ -779,7 +761,7 @@ EOF
assert_equal expected.encoded, created.encoded
assert_nothing_raised do
- TestMailer.deliver_extended_headers @recipient
+ TestMailer.extended_headers(@recipient).deliver
end
delivered = ActionMailer::Base.deliveries.first
@@ -802,7 +784,7 @@ EOF
expected.bcc = quote_address_if_necessary @recipient, "utf-8"
expected.date = Time.local 2004, 12, 12
- created = TestMailer.create_utf8_body @recipient
+ created = TestMailer.utf8_body @recipient
assert_match(/åœö blah/, created.encoded)
end
@@ -817,82 +799,82 @@ EOF
expected.bcc = quote_address_if_necessary @recipient, "utf-8"
expected.date = Time.local 2004, 12, 12
- created = TestMailer.create_utf8_body @recipient
+ created = TestMailer.utf8_body @recipient
assert_match(/\nFrom: =\?utf-8\?Q\?Foo_.*?\?= <extended@example.net>\r/, created.encoded)
assert_match(/\nTo: =\?utf-8\?Q\?Foo_.*?\?= <extended@example.net>, \r\n\tExample Recipient <me/, created.encoded)
end
def test_receive_decodes_base64_encoded_mail
- fixture = File.read(File.dirname(__FILE__) + "/fixtures/raw_email")
+ fixture = File.read(File.dirname(__FILE__) + "/../fixtures/raw_email")
TestMailer.receive(fixture)
assert_match(/Jamis/, TestMailer.received_body.to_s)
end
def test_receive_attachments
- fixture = File.read(File.dirname(__FILE__) + "/fixtures/raw_email2")
+ fixture = File.read(File.dirname(__FILE__) + "/../fixtures/raw_email2")
mail = Mail.new(fixture)
attachment = mail.attachments.last
- assert_equal "smime.p7s", attachment.original_filename
+ assert_equal "smime.p7s", attachment.filename
assert_equal "application/pkcs7-signature", mail.parts.last.mime_type
end
def test_decode_attachment_without_charset
- fixture = File.read(File.dirname(__FILE__) + "/fixtures/raw_email3")
+ fixture = File.read(File.dirname(__FILE__) + "/../fixtures/raw_email3")
mail = Mail.new(fixture)
attachment = mail.attachments.last
assert_equal 1026, attachment.read.length
end
def test_attachment_using_content_location
- fixture = File.read(File.dirname(__FILE__) + "/fixtures/raw_email12")
+ fixture = File.read(File.dirname(__FILE__) + "/../fixtures/raw_email12")
mail = Mail.new(fixture)
assert_equal 1, mail.attachments.length
- assert_equal "Photo25.jpg", mail.attachments.first.original_filename
+ assert_equal "Photo25.jpg", mail.attachments.first.filename
end
def test_attachment_with_text_type
- fixture = File.read(File.dirname(__FILE__) + "/fixtures/raw_email13")
+ fixture = File.read(File.dirname(__FILE__) + "/../fixtures/raw_email13")
mail = Mail.new(fixture)
assert mail.has_attachments?
assert_equal 1, mail.attachments.length
- assert_equal "hello.rb", mail.attachments.first.original_filename
+ assert_equal "hello.rb", mail.attachments.first.filename
end
def test_decode_part_without_content_type
- fixture = File.read(File.dirname(__FILE__) + "/fixtures/raw_email4")
+ fixture = File.read(File.dirname(__FILE__) + "/../fixtures/raw_email4")
mail = Mail.new(fixture)
assert_nothing_raised { mail.body }
end
def test_decode_message_without_content_type
- fixture = File.read(File.dirname(__FILE__) + "/fixtures/raw_email5")
+ fixture = File.read(File.dirname(__FILE__) + "/../fixtures/raw_email5")
mail = Mail.new(fixture)
assert_nothing_raised { mail.body }
end
def test_decode_message_with_incorrect_charset
- fixture = File.read(File.dirname(__FILE__) + "/fixtures/raw_email6")
+ fixture = File.read(File.dirname(__FILE__) + "/../fixtures/raw_email6")
mail = Mail.new(fixture)
assert_nothing_raised { mail.body }
end
def test_multipart_with_mime_version
- mail = TestMailer.create_multipart_with_mime_version(@recipient)
+ mail = TestMailer.multipart_with_mime_version(@recipient)
assert_equal "1.1", mail.mime_version
end
def test_multipart_with_utf8_subject
- mail = TestMailer.create_multipart_with_utf8_subject(@recipient)
+ mail = TestMailer.multipart_with_utf8_subject(@recipient)
assert_match(/\nSubject: =\?utf-8\?Q\?Foo_.*?\?=/, mail.encoded)
end
def test_implicitly_multipart_with_utf8
- mail = TestMailer.create_implicitly_multipart_with_utf8
+ mail = TestMailer.implicitly_multipart_with_utf8
assert_match(/\nSubject: =\?utf-8\?Q\?Foo_.*?\?=/, mail.encoded)
end
def test_explicitly_multipart_messages
- mail = TestMailer.create_explicitly_multipart_example(@recipient)
+ mail = TestMailer.explicitly_multipart_example(@recipient)
assert_equal 3, mail.parts.length
assert_equal 'multipart/mixed', mail.mime_type
assert_equal "text/plain", mail.parts[0].mime_type
@@ -901,6 +883,7 @@ EOF
assert_equal "iso-8859-1", mail.parts[1].charset
assert_equal "image/jpeg", mail.parts[2].mime_type
+
assert_equal "attachment", mail.parts[2][:content_disposition].disposition_type
assert_equal "foo.jpg", mail.parts[2][:content_disposition].filename
assert_equal "foo.jpg", mail.parts[2][:content_type].filename
@@ -908,13 +891,13 @@ EOF
end
def test_explicitly_multipart_with_content_type
- mail = TestMailer.create_explicitly_multipart_example(@recipient, "multipart/alternative")
+ mail = TestMailer.explicitly_multipart_example(@recipient, "multipart/alternative")
assert_equal 3, mail.parts.length
assert_equal "multipart/alternative", mail.mime_type
end
def test_explicitly_multipart_with_invalid_content_type
- mail = TestMailer.create_explicitly_multipart_example(@recipient, "text/xml")
+ mail = TestMailer.explicitly_multipart_example(@recipient, "text/xml")
assert_equal 3, mail.parts.length
assert_equal 'multipart/mixed', mail.mime_type
end
@@ -922,7 +905,7 @@ EOF
def test_implicitly_multipart_messages
assert ActionView::Template.template_handler_extensions.include?("bak"), "bak extension was not registered"
- mail = TestMailer.create_implicitly_multipart_example(@recipient)
+ mail = TestMailer.implicitly_multipart_example(@recipient)
assert_equal 3, mail.parts.length
assert_equal "1.0", mail.mime_version.to_s
assert_equal "multipart/alternative", mail.mime_type
@@ -937,7 +920,7 @@ EOF
def test_implicitly_multipart_messages_with_custom_order
assert ActionView::Template.template_handler_extensions.include?("bak"), "bak extension was not registered"
- mail = TestMailer.create_implicitly_multipart_example(@recipient, nil, ["application/x-yaml", "text/plain"])
+ mail = TestMailer.implicitly_multipart_example(@recipient, nil, ["application/x-yaml", "text/plain"])
assert_equal 3, mail.parts.length
assert_equal "application/x-yaml", mail.parts[0].mime_type
assert_equal "text/plain", mail.parts[1].mime_type
@@ -945,7 +928,7 @@ EOF
end
def test_implicitly_multipart_messages_with_charset
- mail = TestMailer.create_implicitly_multipart_example(@recipient, 'iso-8859-1')
+ mail = TestMailer.implicitly_multipart_example(@recipient, 'iso-8859-1')
assert_equal "multipart/alternative", mail.header['content-type'].content_type
@@ -955,23 +938,23 @@ EOF
end
def test_html_mail
- mail = TestMailer.create_html_mail(@recipient)
+ mail = TestMailer.html_mail(@recipient)
assert_equal "text/html", mail.mime_type
end
def test_html_mail_with_underscores
- mail = TestMailer.create_html_mail_with_underscores(@recipient)
+ mail = TestMailer.html_mail_with_underscores(@recipient)
assert_equal %{<a href="http://google.com" target="_blank">_Google</a>}, mail.body.to_s
end
def test_various_newlines
- mail = TestMailer.create_various_newlines(@recipient)
+ mail = TestMailer.various_newlines(@recipient)
assert_equal("line #1\nline #2\nline #3\nline #4\n\n" +
"line #5\n\nline#6\n\nline #7", mail.body.to_s)
end
def test_various_newlines_multipart
- mail = TestMailer.create_various_newlines_multipart(@recipient)
+ mail = TestMailer.various_newlines_multipart(@recipient)
assert_equal "line #1\nline #2\nline #3\nline #4\n\n", mail.parts[0].body.to_s
assert_equal "<p>line #1</p>\n<p>line #2</p>\n<p>line #3</p>\n<p>line #4</p>\n\n", mail.parts[1].body.to_s
assert_equal "line #1\r\nline #2\r\nline #3\r\nline #4\r\n\r\n", mail.parts[0].body.encoded
@@ -979,8 +962,8 @@ EOF
end
def test_headers_removed_on_smtp_delivery
- ActionMailer::Base.delivery_method = :smtp
- TestMailer.deliver_cc_bcc(@recipient)
+ TestMailer.delivery_method = :smtp
+ TestMailer.cc_bcc(@recipient).deliver
assert MockSMTP.deliveries[0][2].include?("root@loudthinking.com")
assert MockSMTP.deliveries[0][2].include?("nobody@loudthinking.com")
assert MockSMTP.deliveries[0][2].include?(@recipient)
@@ -990,10 +973,10 @@ EOF
end
def test_file_delivery_should_create_a_file
- ActionMailer::Base.delivery_method = :file
- tmp_location = ActionMailer::Base.file_settings[:location]
+ TestMailer.delivery_method = :file
+ tmp_location = TestMailer.file_settings[:location]
- TestMailer.deliver_cc_bcc(@recipient)
+ result = TestMailer.cc_bcc(@recipient).deliver
assert File.exists?(tmp_location)
assert File.directory?(tmp_location)
assert File.exists?(File.join(tmp_location, @recipient))
@@ -1002,7 +985,7 @@ EOF
end
def test_recursive_multipart_processing
- fixture = File.read(File.dirname(__FILE__) + "/fixtures/raw_email7")
+ fixture = File.read(File.dirname(__FILE__) + "/../fixtures/raw_email7")
mail = Mail.new(fixture)
assert_equal(2, mail.parts.length)
assert_equal(4, mail.parts.first.parts.length)
@@ -1013,36 +996,36 @@ EOF
end
def test_decode_encoded_attachment_filename
- fixture = File.read(File.dirname(__FILE__) + "/fixtures/raw_email8")
+ fixture = File.read(File.dirname(__FILE__) + "/../fixtures/raw_email8")
mail = Mail.new(fixture)
attachment = mail.attachments.last
expected = "01 Quien Te Dij\212at. Pitbull.mp3"
if expected.respond_to?(:force_encoding)
- result = attachment.original_filename.dup
+ result = attachment.filename.dup
expected.force_encoding(Encoding::ASCII_8BIT)
result.force_encoding(Encoding::ASCII_8BIT)
assert_equal expected, result
else
- assert_equal expected, attachment.original_filename
+ assert_equal expected, attachment.filename
end
end
def test_decode_message_with_unknown_charset
- fixture = File.read(File.dirname(__FILE__) + "/fixtures/raw_email10")
+ fixture = File.read(File.dirname(__FILE__) + "/../fixtures/raw_email10")
mail = Mail.new(fixture)
assert_nothing_raised { mail.body }
end
def test_empty_header_values_omitted
- result = TestMailer.create_unnamed_attachment(@recipient).encoded
+ result = TestMailer.unnamed_attachment(@recipient).encoded
assert_match %r{Content-Type: application/octet-stream;}, result
- assert_match %r{Content-Disposition: attachment[^;]}, result
+ assert_match %r{Content-Disposition: attachment;}, result
end
def test_headers_with_nonalpha_chars
- mail = TestMailer.create_headers_with_nonalpha_chars(@recipient)
+ mail = TestMailer.headers_with_nonalpha_chars(@recipient)
assert !mail.from_addrs.empty?
assert !mail.cc_addrs.empty?
assert !mail.bcc_addrs.empty?
@@ -1051,98 +1034,90 @@ EOF
assert_match(/:/, mail[:bcc].decoded)
end
- def test_deliver_with_mail_object
- mail = TestMailer.create_headers_with_nonalpha_chars(@recipient)
- assert_nothing_raised { TestMailer.deliver(mail) }
+ def test_with_mail_object_deliver
+ TestMailer.delivery_method = :test
+ mail = TestMailer.headers_with_nonalpha_chars(@recipient)
+ assert_nothing_raised { mail.deliver }
assert_equal 1, TestMailer.deliveries.length
end
def test_multipart_with_template_path_with_dots
- mail = FunkyPathMailer.create_multipart_with_template_path_with_dots(@recipient)
+ mail = FunkyPathMailer.multipart_with_template_path_with_dots(@recipient)
assert_equal 2, mail.parts.length
assert "text/plain", mail.parts[1].mime_type
assert "utf-8", mail.parts[1].charset
end
def test_custom_content_type_attributes
- mail = TestMailer.create_custom_content_type_attributes
+ mail = TestMailer.custom_content_type_attributes
assert_match %r{format=flowed}, mail.content_type
assert_match %r{charset=utf-8}, mail.content_type
end
def test_return_path_with_create
- mail = TestMailer.create_return_path
- assert_equal "another@somewhere.test", mail['return-path'].to_s
- end
-
- def test_return_path_with_create
- mail = TestMailer.create_return_path
- assert_equal ["another@somewhere.test"], mail.return_path
+ mail = TestMailer.return_path
+ assert_equal "another@somewhere.test", mail.return_path
end
def test_return_path_with_deliver
- ActionMailer::Base.delivery_method = :smtp
- TestMailer.deliver_return_path
+ TestMailer.delivery_method = :smtp
+ TestMailer.return_path.deliver
assert_match %r{^Return-Path: <another@somewhere.test>}, MockSMTP.deliveries[0][0]
assert_equal "another@somewhere.test", MockSMTP.deliveries[0][1].to_s
end
- def test_body_is_stored_as_an_ivar
- mail = TestMailer.create_body_ivar(@recipient)
- assert_equal "body: foo\nbar: baz", mail.body.to_s
- end
-
def test_starttls_is_enabled_if_supported
- ActionMailer::Base.smtp_settings[:enable_starttls_auto] = true
+ TestMailer.smtp_settings.merge!(:enable_starttls_auto => true)
MockSMTP.any_instance.expects(:respond_to?).with(:enable_starttls_auto).returns(true)
MockSMTP.any_instance.expects(:enable_starttls_auto)
- ActionMailer::Base.delivery_method = :smtp
- TestMailer.deliver_signed_up(@recipient)
+ TestMailer.delivery_method = :smtp
+ TestMailer.signed_up(@recipient).deliver
end
def test_starttls_is_disabled_if_not_supported
- ActionMailer::Base.smtp_settings[:enable_starttls_auto] = true
+ TestMailer.smtp_settings.merge!(:enable_starttls_auto => true)
MockSMTP.any_instance.expects(:respond_to?).with(:enable_starttls_auto).returns(false)
MockSMTP.any_instance.expects(:enable_starttls_auto).never
- ActionMailer::Base.delivery_method = :smtp
- TestMailer.deliver_signed_up(@recipient)
+ TestMailer.delivery_method = :smtp
+ TestMailer.signed_up(@recipient).deliver
end
def test_starttls_is_not_enabled
- ActionMailer::Base.smtp_settings[:enable_starttls_auto] = false
+ TestMailer.smtp_settings.merge!(:enable_starttls_auto => false)
MockSMTP.any_instance.expects(:respond_to?).never
- MockSMTP.any_instance.expects(:enable_starttls_auto).never
- ActionMailer::Base.delivery_method = :smtp
- TestMailer.deliver_signed_up(@recipient)
+ TestMailer.delivery_method = :smtp
+ TestMailer.signed_up(@recipient).deliver
ensure
- ActionMailer::Base.smtp_settings[:enable_starttls_auto] = true
+ TestMailer.smtp_settings.merge!(:enable_starttls_auto => true)
end
end
-class InheritableTemplateRootTest < Test::Unit::TestCase
+class InheritableTemplateRootTest < ActiveSupport::TestCase
def test_attr
- expected = File.expand_path("#{File.dirname(__FILE__)}/fixtures/path.with.dots")
+ expected = File.expand_path("#{File.dirname(__FILE__)}/../fixtures/path.with.dots")
assert_equal expected, FunkyPathMailer.template_root.to_s
sub = Class.new(FunkyPathMailer)
- sub.template_root = 'test/path'
+ assert_deprecated do
+ sub.template_root = 'test/path'
+ end
assert_equal File.expand_path('test/path'), sub.template_root.to_s
assert_equal expected, FunkyPathMailer.template_root.to_s
end
end
-class MethodNamingTest < Test::Unit::TestCase
+class MethodNamingTest < ActiveSupport::TestCase
class TestMailer < ActionMailer::Base
def send
- render :text => 'foo'
+ body 'foo'
end
end
def setup
set_delivery_method :test
ActionMailer::Base.perform_deliveries = true
- ActionMailer::Base.deliveries = []
+ ActionMailer::Base.deliveries.clear
end
def teardown
@@ -1152,12 +1127,13 @@ class MethodNamingTest < Test::Unit::TestCase
def test_send_method
assert_nothing_raised do
assert_emails 1 do
- TestMailer.deliver_send
+ assert_deprecated do
+ TestMailer.deliver_send
+ end
end
end
end
end
-
class RespondToTest < Test::Unit::TestCase
class RespondToMailer < ActionMailer::Base; end
@@ -1220,4 +1196,4 @@ class RespondToTest < Test::Unit::TestCase
assert_match(/undefined method.*not_a_method/, error.message)
end
-end
+end \ No newline at end of file
diff --git a/actionmailer/test/tmail_compat_test.rb b/actionmailer/test/old_base/tmail_compat_test.rb
index a1ca6a7243..7c1d9a07c1 100644
--- a/actionmailer/test/tmail_compat_test.rb
+++ b/actionmailer/test/old_base/tmail_compat_test.rb
@@ -1,21 +1,23 @@
require 'abstract_unit'
-class TmailCompatTest < Test::Unit::TestCase
+class TmailCompatTest < ActiveSupport::TestCase
def test_set_content_type_raises_deprecation_warning
mail = Mail.new
- STDERR.expects(:puts) # Deprecation warning
- assert_nothing_raised do
- mail.set_content_type "text/plain"
+ assert_deprecated do
+ assert_nothing_raised do
+ mail.set_content_type "text/plain"
+ end
end
assert_equal mail.mime_type, "text/plain"
end
def test_transfer_encoding_raises_deprecation_warning
mail = Mail.new
- STDERR.expects(:puts) # Deprecation warning
- assert_nothing_raised do
- mail.transfer_encoding "base64"
+ assert_deprecated do
+ assert_nothing_raised do
+ mail.transfer_encoding "base64"
+ end
end
assert_equal mail.content_transfer_encoding, "base64"
end
diff --git a/actionmailer/test/url_test.rb b/actionmailer/test/old_base/url_test.rb
index 12bf609dce..5affb47997 100644
--- a/actionmailer/test/url_test.rb
+++ b/actionmailer/test/old_base/url_test.rb
@@ -44,7 +44,7 @@ class ActionMailerUrlTest < Test::Unit::TestCase
def setup
set_delivery_method :test
ActionMailer::Base.perform_deliveries = true
- ActionMailer::Base.deliveries = []
+ ActionMailer::Base.deliveries.clear
@recipient = 'test@localhost'
end
@@ -54,6 +54,8 @@ class ActionMailerUrlTest < Test::Unit::TestCase
end
def test_signed_up_with_url
+ TestMailer.delivery_method = :test
+
ActionController::Routing::Routes.draw do |map|
map.connect ':controller/:action/:id'
map.welcome 'welcome', :controller=>"foo", :action=>"bar"
@@ -67,14 +69,14 @@ class ActionMailerUrlTest < Test::Unit::TestCase
expected.date = Time.local(2004, 12, 12)
created = nil
- assert_nothing_raised { created = TestMailer.create_signed_up_with_url(@recipient) }
+ assert_nothing_raised { created = TestMailer.signed_up_with_url(@recipient) }
assert_not_nil created
expected.message_id = '<123@456>'
created.message_id = '<123@456>'
assert_equal expected.encoded, created.encoded
- assert_nothing_raised { TestMailer.deliver_signed_up_with_url(@recipient) }
+ assert_nothing_raised { TestMailer.signed_up_with_url(@recipient).deliver }
assert_not_nil ActionMailer::Base.deliveries.first
delivered = ActionMailer::Base.deliveries.first
diff --git a/actionmailer/test/subscriber_test.rb b/actionmailer/test/subscriber_test.rb
index aed5d2ca7e..3d1736d64f 100644
--- a/actionmailer/test/subscriber_test.rb
+++ b/actionmailer/test/subscriber_test.rb
@@ -11,7 +11,7 @@ class AMSubscriberTest < ActionMailer::TestCase
recipients "somewhere@example.com"
subject "basic"
from "basic@example.com"
- render :text => "Hello world"
+ body "Hello world"
end
def receive(mail)
@@ -24,21 +24,21 @@ class AMSubscriberTest < ActionMailer::TestCase
end
def test_deliver_is_notified
- TestMailer.deliver_basic
+ TestMailer.basic.deliver
wait
- assert_equal 1, @logger.logged(:info).size
- assert_match /Sent mail to somewhere@example.com/, @logger.logged(:info).first
- assert_equal 1, @logger.logged(:debug).size
- assert_match /Hello world/, @logger.logged(:debug).first
+ assert_equal(1, @logger.logged(:info).size)
+ assert_match(/Sent mail to somewhere@example.com/, @logger.logged(:info).first)
+ assert_equal(1, @logger.logged(:debug).size)
+ assert_match(/Hello world/, @logger.logged(:debug).first)
end
def test_receive_is_notified
fixture = File.read(File.dirname(__FILE__) + "/fixtures/raw_email")
TestMailer.receive(fixture)
wait
- assert_equal 1, @logger.logged(:info).size
- assert_match /Received mail/, @logger.logged(:info).first
- assert_equal 1, @logger.logged(:debug).size
- assert_match /Jamis/, @logger.logged(:debug).first
+ assert_equal(1, @logger.logged(:info).size)
+ assert_match(/Received mail/, @logger.logged(:info).first)
+ assert_equal(1, @logger.logged(:debug).size)
+ assert_match(/Jamis/, @logger.logged(:debug).first)
end
end \ No newline at end of file
diff --git a/actionmailer/test/test_helper_test.rb b/actionmailer/test/test_helper_test.rb
index 1fed26f78f..3a38a91c28 100644
--- a/actionmailer/test/test_helper_test.rb
+++ b/actionmailer/test/test_helper_test.rb
@@ -12,7 +12,7 @@ end
class TestHelperMailerTest < ActionMailer::TestCase
def test_setup_sets_right_action_mailer_options
- assert_instance_of ActionMailer::DeliveryMethod::Test, ActionMailer::Base.delivery_method
+ assert_equal :test, ActionMailer::Base.delivery_method
assert ActionMailer::Base.perform_deliveries
assert_equal [], ActionMailer::Base.deliveries
end
@@ -44,7 +44,7 @@ class TestHelperMailerTest < ActionMailer::TestCase
def test_assert_emails
assert_nothing_raised do
assert_emails 1 do
- TestHelperMailer.deliver_test
+ TestHelperMailer.test.deliver
end
end
end
@@ -52,27 +52,27 @@ class TestHelperMailerTest < ActionMailer::TestCase
def test_repeated_assert_emails_calls
assert_nothing_raised do
assert_emails 1 do
- TestHelperMailer.deliver_test
+ TestHelperMailer.test.deliver
end
end
assert_nothing_raised do
assert_emails 2 do
- TestHelperMailer.deliver_test
- TestHelperMailer.deliver_test
+ TestHelperMailer.test.deliver
+ TestHelperMailer.test.deliver
end
end
end
def test_assert_emails_with_no_block
assert_nothing_raised do
- TestHelperMailer.deliver_test
+ TestHelperMailer.test.deliver
assert_emails 1
end
assert_nothing_raised do
- TestHelperMailer.deliver_test
- TestHelperMailer.deliver_test
+ TestHelperMailer.test.deliver
+ TestHelperMailer.test.deliver
assert_emails 3
end
end
@@ -80,7 +80,7 @@ class TestHelperMailerTest < ActionMailer::TestCase
def test_assert_no_emails
assert_nothing_raised do
assert_no_emails do
- TestHelperMailer.create_test
+ TestHelperMailer.test
end
end
end
@@ -88,7 +88,7 @@ class TestHelperMailerTest < ActionMailer::TestCase
def test_assert_emails_too_few_sent
error = assert_raise ActiveSupport::TestCase::Assertion do
assert_emails 2 do
- TestHelperMailer.deliver_test
+ TestHelperMailer.test.deliver
end
end
@@ -98,8 +98,8 @@ class TestHelperMailerTest < ActionMailer::TestCase
def test_assert_emails_too_many_sent
error = assert_raise ActiveSupport::TestCase::Assertion do
assert_emails 1 do
- TestHelperMailer.deliver_test
- TestHelperMailer.deliver_test
+ TestHelperMailer.test.deliver
+ TestHelperMailer.test.deliver
end
end
@@ -109,7 +109,7 @@ class TestHelperMailerTest < ActionMailer::TestCase
def test_assert_no_emails_failure
error = assert_raise ActiveSupport::TestCase::Assertion do
assert_no_emails do
- TestHelperMailer.deliver_test
+ TestHelperMailer.test.deliver
end
end
diff --git a/actionpack/lib/abstract_controller.rb b/actionpack/lib/abstract_controller.rb
index 725d8fb8fc..2c2ef16622 100644
--- a/actionpack/lib/abstract_controller.rb
+++ b/actionpack/lib/abstract_controller.rb
@@ -10,6 +10,7 @@ module AbstractController
autoload :Base
autoload :Callbacks
+ autoload :Collector
autoload :Helpers
autoload :Layouts
autoload :LocalizedCache
diff --git a/actionpack/lib/abstract_controller/collector.rb b/actionpack/lib/abstract_controller/collector.rb
new file mode 100644
index 0000000000..d429333661
--- /dev/null
+++ b/actionpack/lib/abstract_controller/collector.rb
@@ -0,0 +1,30 @@
+module AbstractController
+ module Collector
+ def self.generate_method_for_mime(mime)
+ sym = mime.is_a?(Symbol) ? mime : mime.to_sym
+ const = sym.to_s.upcase
+ class_eval <<-RUBY, __FILE__, __LINE__ + 1
+ def #{sym}(*args, &block) # def html(*args, &block)
+ custom(Mime::#{const}, *args, &block) # custom(Mime::HTML, *args, &block)
+ end # end
+ RUBY
+ end
+
+ Mime::SET.each do |mime|
+ generate_method_for_mime(mime)
+ end
+
+ protected
+
+ def method_missing(symbol, &block)
+ mime_constant = Mime.const_get(symbol.to_s.upcase)
+
+ if Mime::SET.include?(mime_constant)
+ AbstractController::Collector.generate_method_for_mime(mime_constant)
+ send(symbol, &block)
+ else
+ super
+ end
+ end
+ end
+end \ No newline at end of file
diff --git a/actionpack/lib/abstract_controller/layouts.rb b/actionpack/lib/abstract_controller/layouts.rb
index 6fbf6bc392..56ddf9bf01 100644
--- a/actionpack/lib/abstract_controller/layouts.rb
+++ b/actionpack/lib/abstract_controller/layouts.rb
@@ -270,6 +270,9 @@ module AbstractController
end
end
ruby_eval
+ when Proc
+ define_method :_layout_from_proc, &@_layout
+ self.class_eval %{def _layout(details) _layout_from_proc(self) end}
when false
self.class_eval %{def _layout(details) end}
when true
diff --git a/actionpack/lib/abstract_controller/rendering.rb b/actionpack/lib/abstract_controller/rendering.rb
index a168b1b4c5..1dec3f2c3e 100644
--- a/actionpack/lib/abstract_controller/rendering.rb
+++ b/actionpack/lib/abstract_controller/rendering.rb
@@ -41,10 +41,6 @@ module AbstractController
# Mostly abstracts the fact that calling render twice is a DoubleRenderError.
# Delegates render_to_body and sticks the result in self.response_body.
def render(*args, &block)
- if response_body
- raise AbstractController::DoubleRenderError
- end
-
options = _normalize_options(*args, &block)
self.response_body = render_to_body(options)
end
diff --git a/actionpack/lib/action_controller/base.rb b/actionpack/lib/action_controller/base.rb
index f46231d72b..215b70734c 100644
--- a/actionpack/lib/action_controller/base.rb
+++ b/actionpack/lib/action_controller/base.rb
@@ -7,7 +7,6 @@ module ActionController
include AbstractController::Translation
include ActionController::Helpers
- helper :all # By default, all helpers should be included
include ActionController::HideActions
include ActionController::UrlFor
@@ -67,6 +66,7 @@ module ActionController
def self.inherited(klass)
::ActionController::Base.subclasses << klass.to_s
super
+ klass.helper :all
end
def self.subclasses
diff --git a/actionpack/lib/action_controller/deprecated.rb b/actionpack/lib/action_controller/deprecated.rb
index 589061e77c..edc0e5b3fe 100644
--- a/actionpack/lib/action_controller/deprecated.rb
+++ b/actionpack/lib/action_controller/deprecated.rb
@@ -2,3 +2,4 @@ ActionController::AbstractRequest = ActionController::Request = ActionDispatch::
ActionController::AbstractResponse = ActionController::Response = ActionDispatch::Response
ActionController::Routing = ActionDispatch::Routing
ActionController::Routing::Routes = ActionDispatch::Routing::RouteSet.new
+ActionController::UrlWriter = AbstractController::UrlFor
diff --git a/actionpack/lib/action_controller/metal/helpers.rb b/actionpack/lib/action_controller/metal/helpers.rb
index cdd14560e1..03ba4b3f83 100644
--- a/actionpack/lib/action_controller/metal/helpers.rb
+++ b/actionpack/lib/action_controller/metal/helpers.rb
@@ -50,13 +50,19 @@ module ActionController
include AbstractController::Helpers
included do
- # Set the default directory for helpers
- extlib_inheritable_accessor(:helpers_dir) do
- defined?(Rails.root) ? "#{Rails.root}/app/helpers" : "app/helpers"
- end
+ extlib_inheritable_accessor(:helpers_path)
+ self.helpers_path = []
end
module ClassMethods
+ def helpers_dir
+ self.helpers_path
+ end
+
+ def helpers_dir=(value)
+ self.helpers_path = Array(value)
+ end
+
def inherited(klass)
klass.class_eval { default_helper_module! unless name.blank? }
super
@@ -80,36 +86,42 @@ module ActionController
@helper_proxy ||= ActionView::Base.new.extend(_helpers)
end
- private
- # Overwrite _modules_for_helpers to accept :all as argument, which loads
- # all helpers in helpers_dir.
- #
- # ==== Parameters
- # args<Array[String, Symbol, Module, all]>:: A list of helpers
- #
- # ==== Returns
- # Array[Module]:: A normalized list of modules for the list of
- # helpers provided.
- def _modules_for_helpers(args)
- args += all_application_helpers if args.delete(:all)
- super(args)
- end
+ private
+ # Overwrite _modules_for_helpers to accept :all as argument, which loads
+ # all helpers in helpers_dir.
+ #
+ # ==== Parameters
+ # args<Array[String, Symbol, Module, all]>:: A list of helpers
+ #
+ # ==== Returns
+ # Array[Module]:: A normalized list of modules for the list of
+ # helpers provided.
+ def _modules_for_helpers(args)
+ args += all_application_helpers if args.delete(:all)
+ super(args)
+ end
- def default_helper_module!
- module_name = name.sub(/Controller$/, '')
- module_path = module_name.underscore
- helper module_path
- rescue MissingSourceFile => e
- raise e unless e.is_missing? "helpers/#{module_path}_helper"
- rescue NameError => e
- raise e unless e.missing_name? "#{module_name}Helper"
- end
+ def default_helper_module!
+ module_name = name.sub(/Controller$/, '')
+ module_path = module_name.underscore
+ helper module_path
+ rescue MissingSourceFile => e
+ raise e unless e.is_missing? "helpers/#{module_path}_helper"
+ rescue NameError => e
+ raise e unless e.missing_name? "#{module_name}Helper"
+ end
- # Extract helper names from files in app/helpers/**/*.rb
- def all_application_helpers
- extract = /^#{Regexp.quote(helpers_dir)}\/?(.*)_helper.rb$/
- Dir["#{helpers_dir}/**/*_helper.rb"].map { |file| file.sub extract, '\1' }
- end
+ # Extract helper names from files in app/helpers/**/*_helper.rb
+ def all_application_helpers
+ helpers = []
+ helpers_path.each do |path|
+ extract = /^#{Regexp.quote(path)}\/?(.*)_helper.rb$/
+ helpers += Dir["#{path}/**/*_helper.rb"].map { |file| file.sub(extract, '\1') }
+ end
+ helpers.sort!
+ helpers.uniq!
+ helpers
+ end
end
end
end
diff --git a/actionpack/lib/action_controller/metal/mime_responds.rb b/actionpack/lib/action_controller/metal/mime_responds.rb
index 4c02677729..08599d660e 100644
--- a/actionpack/lib/action_controller/metal/mime_responds.rb
+++ b/actionpack/lib/action_controller/metal/mime_responds.rb
@@ -1,3 +1,5 @@
+require 'abstract_controller/collector'
+
module ActionController #:nodoc:
module MimeResponds #:nodoc:
extend ActiveSupport::Concern
@@ -265,6 +267,7 @@ module ActionController #:nodoc:
end
class Collector #:nodoc:
+ include AbstractController::Collector
attr_accessor :order
def initialize(&block)
@@ -289,32 +292,6 @@ module ActionController #:nodoc:
def response_for(mime)
@responses[mime] || @responses[Mime::ALL] || @default_response
end
-
- def self.generate_method_for_mime(mime)
- sym = mime.is_a?(Symbol) ? mime : mime.to_sym
- const = sym.to_s.upcase
- class_eval <<-RUBY, __FILE__, __LINE__ + 1
- def #{sym}(&block) # def html(&block)
- custom(Mime::#{const}, &block) # custom(Mime::HTML, &block)
- end # end
- RUBY
- end
-
- Mime::SET.each do |mime|
- generate_method_for_mime(mime)
- end
-
- def method_missing(symbol, &block)
- mime_constant = Mime.const_get(symbol.to_s.upcase)
-
- if Mime::SET.include?(mime_constant)
- self.class.generate_method_for_mime(mime_constant)
- send(symbol, &block)
- else
- super
- end
- end
-
end
end
end
diff --git a/actionpack/lib/action_controller/metal/rendering.rb b/actionpack/lib/action_controller/metal/rendering.rb
index 72e2bbd00e..8f03035b2b 100644
--- a/actionpack/lib/action_controller/metal/rendering.rb
+++ b/actionpack/lib/action_controller/metal/rendering.rb
@@ -13,6 +13,10 @@ module ActionController
end
def render(*args)
+ if response_body
+ raise ::AbstractController::DoubleRenderError
+ end
+
args << {} unless args.last.is_a?(Hash)
super(*args)
self.content_type ||= args.last[:_template].mime_type.to_s
diff --git a/actionpack/lib/action_controller/railtie.rb b/actionpack/lib/action_controller/railtie.rb
index 7ea64c1923..9151de4462 100644
--- a/actionpack/lib/action_controller/railtie.rb
+++ b/actionpack/lib/action_controller/railtie.rb
@@ -3,41 +3,27 @@ require "rails"
module ActionController
class Railtie < Rails::Railtie
- plugin_name :action_controller
+ railtie_name :action_controller
require "action_controller/railties/subscriber"
subscriber ActionController::Railties::Subscriber.new
- initializer "action_controller.set_configs" do |app|
- app.config.action_controller.each do |k,v|
- ActionController::Base.send "#{k}=", v
- end
- end
-
- # TODO: ActionController::Base.logger should delegate to its own config.logger
initializer "action_controller.logger" do
ActionController::Base.logger ||= Rails.logger
end
- # Routing must be initialized after plugins to allow the former to extend the routes
- initializer "action_controller.initialize_routing" do |app|
- app.route_configuration_files << app.config.routes_configuration_file
- app.route_configuration_files << app.config.builtin_routes_configuration_file
+ initializer "action_controller.set_configs" do |app|
+ app.config.action_controller.each do |k,v|
+ ActionController::Base.send "#{k}=", v
+ end
end
initializer "action_controller.initialize_framework_caches" do
ActionController::Base.cache_store ||= RAILS_CACHE
end
- # Sets +ActionController::Base#view_paths+ and +ActionMailer::Base#template_root+
- # (but only for those frameworks that are to be loaded). If the framework's
- # paths have already been set, it is not changed, otherwise it is
- # set to use Configuration#view_path.
- initializer "action_controller.initialize_framework_views" do |app|
- # TODO: this should be combined with the logic for default config.action_controller.view_paths
- view_path = ActionView::PathSet.type_cast(app.config.view_path, app.config.cache_classes)
- ActionController::Base.view_paths = view_path if ActionController::Base.view_paths.blank?
+ initializer "action_controller.set_helpers_path" do |app|
+ ActionController::Base.helpers_path = app.config.paths.app.helpers.to_a
end
-
end
end
diff --git a/actionpack/lib/action_dispatch/middleware/callbacks.rb b/actionpack/lib/action_dispatch/middleware/callbacks.rb
index d07841218a..7cf75ffe63 100644
--- a/actionpack/lib/action_dispatch/middleware/callbacks.rb
+++ b/actionpack/lib/action_dispatch/middleware/callbacks.rb
@@ -37,7 +37,7 @@ module ActionDispatch
def initialize(app, prepare_each_request = false)
@app, @prepare_each_request = app, prepare_each_request
- run_callbacks(:prepare)
+ run_callbacks(:prepare) unless @prepare_each_request
end
def call(env)
diff --git a/actionpack/lib/action_dispatch/middleware/stack.rb b/actionpack/lib/action_dispatch/middleware/stack.rb
index 0dc1d70e37..18a2922fa7 100644
--- a/actionpack/lib/action_dispatch/middleware/stack.rb
+++ b/actionpack/lib/action_dispatch/middleware/stack.rb
@@ -55,7 +55,11 @@ module ActionDispatch
when Class
klass == middleware
else
- klass == ActiveSupport::Inflector.constantize(middleware.to_s)
+ if lazy_compare?(@klass) && lazy_compare?(middleware)
+ normalize(@klass) == normalize(middleware)
+ else
+ klass == ActiveSupport::Inflector.constantize(middleware.to_s)
+ end
end
end
@@ -72,6 +76,14 @@ module ActionDispatch
end
private
+ def lazy_compare?(object)
+ object.is_a?(String) || object.is_a?(Symbol)
+ end
+
+ def normalize(object)
+ object.to_s.strip.sub(/^::/, '')
+ end
+
def build_args
Array(args).map { |arg| arg.respond_to?(:call) ? arg.call : arg }
end
diff --git a/actionpack/lib/action_dispatch/railtie.rb b/actionpack/lib/action_dispatch/railtie.rb
index e4bd143e78..335daafc01 100644
--- a/actionpack/lib/action_dispatch/railtie.rb
+++ b/actionpack/lib/action_dispatch/railtie.rb
@@ -3,24 +3,13 @@ require "rails"
module ActionDispatch
class Railtie < Rails::Railtie
- plugin_name :action_dispatch
+ railtie_name :action_dispatch
# Prepare dispatcher callbacks and run 'prepare' callbacks
initializer "action_dispatch.prepare_dispatcher" do |app|
# TODO: This used to say unless defined?(Dispatcher). Find out why and fix.
require 'rails/dispatcher'
-
- unless app.config.cache_classes
- # Setup dev mode route reloading
- routes_last_modified = app.routes_changed_at
- reload_routes = lambda do
- unless app.routes_changed_at == routes_last_modified
- routes_last_modified = app.routes_changed_at
- app.reload_routes!
- end
- end
- ActionDispatch::Callbacks.before { |callbacks| reload_routes.call }
- end
+ ActionDispatch::Callbacks.to_prepare { app.routes_reloader.reload_if_changed }
end
end
end \ No newline at end of file
diff --git a/actionpack/lib/action_dispatch/routing/mapper.rb b/actionpack/lib/action_dispatch/routing/mapper.rb
index fcbb70749f..5199984814 100644
--- a/actionpack/lib/action_dispatch/routing/mapper.rb
+++ b/actionpack/lib/action_dispatch/routing/mapper.rb
@@ -157,10 +157,11 @@ module ActionDispatch
end
# Invokes Rack::Mount::Utils.normalize path and ensure that
- # (:locale) becomes (/:locale) instead of /(:locale).
+ # (:locale) becomes (/:locale) instead of /(:locale). Except
+ # for root cases, where the latter is the correct one.
def self.normalize_path(path)
path = Rack::Mount::Utils.normalize_path(path)
- path.sub!(%r{/\(+/?:}, '(/:')
+ path.sub!(%r{/(\(+)/?:}, '\1/:') unless path =~ %r{^/\(+:.*\)$}
path
end
diff --git a/actionpack/lib/action_dispatch/routing/route_set.rb b/actionpack/lib/action_dispatch/routing/route_set.rb
index 660d28dbec..c49ac70562 100644
--- a/actionpack/lib/action_dispatch/routing/route_set.rb
+++ b/actionpack/lib/action_dispatch/routing/route_set.rb
@@ -222,19 +222,18 @@ module ActionDispatch
end
end
- attr_accessor :routes, :named_routes
- attr_accessor :disable_clear_and_finalize
+ attr_accessor :routes, :named_routes, :controller_namespaces
+ attr_accessor :disable_clear_and_finalize, :resources_path_names
def self.default_resources_path_names
{ :new => 'new', :edit => 'edit' }
end
- attr_accessor :resources_path_names
-
def initialize
self.routes = []
self.named_routes = NamedRouteCollection.new
- self.resources_path_names = self.class.default_resources_path_names
+ self.resources_path_names = self.class.default_resources_path_names.dup
+ self.controller_namespaces = Set.new
@disable_clear_and_finalize = false
end
@@ -281,32 +280,19 @@ module ActionDispatch
def controller_constraints
@controller_constraints ||= begin
- source = controller_namespaces.map { |ns| "#{Regexp.escape(ns)}/#{CONTROLLER_REGEXP.source}" }
+ namespaces = controller_namespaces + in_memory_controller_namespaces
+ source = namespaces.map { |ns| "#{Regexp.escape(ns)}/#{CONTROLLER_REGEXP.source}" }
source << CONTROLLER_REGEXP.source
Regexp.compile(source.sort.reverse.join('|'))
end
end
- def controller_namespaces
+ def in_memory_controller_namespaces
namespaces = Set.new
-
- # Find any nested controllers already in memory
ActionController::Base.subclasses.each do |klass|
controller_name = klass.underscore
namespaces << controller_name.split('/')[0...-1].join('/')
end
-
- # TODO: Move this into Railties
- if defined?(Rails.application)
- # Find namespaces in controllers/ directory
- Rails.application.config.controller_paths.each do |load_path|
- load_path = File.expand_path(load_path)
- Dir["#{load_path}/**/*_controller.rb"].collect do |path|
- namespaces << File.dirname(path).sub(/#{load_path}\/?/, '')
- end
- end
- end
-
namespaces.delete('')
namespaces
end
diff --git a/actionpack/lib/action_view/base.rb b/actionpack/lib/action_view/base.rb
index c4b0455c2a..af13f2cd3e 100644
--- a/actionpack/lib/action_view/base.rb
+++ b/actionpack/lib/action_view/base.rb
@@ -276,9 +276,11 @@ module ActionView #:nodoc:
@config = nil
@formats = formats
@assigns = assigns_for_first_render.each { |key, value| instance_variable_set("@#{key}", value) }
- @_controller = controller
@helpers = self.class.helpers || Module.new
- @_content_for = Hash.new {|h,k| h[k] = ActionView::SafeBuffer.new }
+
+ @_controller = controller
+ @_content_for = Hash.new {|h,k| h[k] = ActionView::SafeBuffer.new }
+ @_virtual_path = nil
self.view_paths = view_paths
end
diff --git a/actionpack/lib/action_view/helpers.rb b/actionpack/lib/action_view/helpers.rb
index 3d088678fc..080eb87445 100644
--- a/actionpack/lib/action_view/helpers.rb
+++ b/actionpack/lib/action_view/helpers.rb
@@ -3,7 +3,7 @@ require 'active_support/benchmarkable'
module ActionView #:nodoc:
module Helpers #:nodoc:
autoload :ActiveModelHelper, 'action_view/helpers/active_model_helper'
- autoload :AjaxHelper, 'action_view/helpers/ajax_helper'
+ autoload :AjaxHelperCompat, 'action_view/helpers/ajax_helper'
autoload :AssetTagHelper, 'action_view/helpers/asset_tag_helper'
autoload :AtomFeedHelper, 'action_view/helpers/atom_feed_helper'
autoload :CacheHelper, 'action_view/helpers/cache_helper'
@@ -15,12 +15,11 @@ module ActionView #:nodoc:
autoload :FormTagHelper, 'action_view/helpers/form_tag_helper'
autoload :JavaScriptHelper, 'action_view/helpers/javascript_helper'
autoload :NumberHelper, 'action_view/helpers/number_helper'
- autoload :PrototypeHelper, 'action_view/helpers/prototype_helper'
+ autoload :AjaxHelper, 'action_view/helpers/ajax_helper'
autoload :RawOutputHelper, 'action_view/helpers/raw_output_helper'
autoload :RecordIdentificationHelper, 'action_view/helpers/record_identification_helper'
autoload :RecordTagHelper, 'action_view/helpers/record_tag_helper'
autoload :SanitizeHelper, 'action_view/helpers/sanitize_helper'
- autoload :ScriptaculousHelper, 'action_view/helpers/scriptaculous_helper'
autoload :TagHelper, 'action_view/helpers/tag_helper'
autoload :TextHelper, 'action_view/helpers/text_helper'
autoload :TranslationHelper, 'action_view/helpers/translation_helper'
@@ -48,12 +47,11 @@ module ActionView #:nodoc:
include FormTagHelper
include JavaScriptHelper
include NumberHelper
- include PrototypeHelper
+ include AjaxHelperCompat
include RawOutputHelper
include RecordIdentificationHelper
include RecordTagHelper
include SanitizeHelper
- include ScriptaculousHelper
include TagHelper
include TextHelper
include TranslationHelper
diff --git a/actionpack/lib/action_view/helpers/ajax_helper.rb b/actionpack/lib/action_view/helpers/ajax_helper.rb
index 9cc2acc239..169a803848 100644
--- a/actionpack/lib/action_view/helpers/ajax_helper.rb
+++ b/actionpack/lib/action_view/helpers/ajax_helper.rb
@@ -1,68 +1,713 @@
module ActionView
module Helpers
module AjaxHelper
- include UrlHelper
-
- def link_to_remote(name, url, options = {})
- html = options.delete(:html) || {}
-
- update = options.delete(:update)
- if update.is_a?(Hash)
- html["data-update-success"] = update[:success]
- html["data-update-failure"] = update[:failure]
- else
- html["data-update-success"] = update
+ # Included for backwards compatibility / RJS functionality
+ # Rails classes should not be aware of individual JS frameworks
+ include PrototypeHelper
+
+ # Returns a form that will allow the unobtrusive JavaScript drivers to submit the
+ # form dynamically. The default driver behaviour is an XMLHttpRequest in the background
+ # instead of the regular POST arrangement. Even though it's using JavaScript to serialize
+ # the form elements, the form submission will work just like a regular submission as
+ # viewed by the receiving side (all elements available in <tt>params</tt>). The options
+ # for specifying the target with <tt>:url</tt> anddefining callbacks is the same as +link_to_remote+.
+ #
+ # === Resource
+ #
+ # Example:
+ #
+ # # Generates:
+ # # <form action='/authors'
+ # # data-remote='true'
+ # # class='new_author'
+ # # id='create-author'
+ # # method='post'> ... </form>
+ # #
+ # <% remote_form_for(@record, {:html => { :id => 'create-author' }}) do |f| %>
+ # ...
+ # <% end %>
+ #
+ # This will expand to be the same as:
+ #
+ # <% remote_form_for :post, @post, :url => post_path(@post),
+ # :html => { :method => :put,
+ # :class => "edit_post",
+ # :id => "edit_post_45" } do |f| %>
+ # ...
+ # <% end %>
+ #
+ # === Nested Resource
+ #
+ # Example:
+ # # Generates:
+ # # <form action='/authors/1/articles'
+ # # data-remote="true"
+ # # class='new_article'
+ # # method='post'
+ # # id='new_article'></form>
+ # #
+ # <% remote_form_for([@author, @article]) do |f| %>
+ # ...
+ # <% end %>
+ #
+ # This will expand to be the same as:
+ #
+ # <% remote_form_for :article, @article, :url => author_article_path(@author, @article),
+ # :html => { :method => :put,
+ # :class => "new_article",
+ # :id => "new_comment" } do |f| %>
+ # ...
+ # <% end %>
+ #
+ # If you don't need to attach a form to a resource, then check out form_remote_tag.
+ #
+ # See FormHelper#form_for for additional semantics.
+ def remote_form_for(record_or_name_or_array, *args, &proc)
+ options = args.extract_options!
+
+ if confirm = options.delete(:confirm)
+ add_confirm_to_attributes!(options, confirm)
end
- html["data-update-position"] = options.delete(:position)
- html["data-method"] = options.delete(:method)
- html["data-remote"] = "true"
-
- html.merge!(options)
+ object_name = extract_object_name_for_form!(args, options, record_or_name_or_array)
+
+ concat(form_remote_tag(options))
+ fields_for(object_name, *(args << options), &proc)
+ concat('</form>'.html_safe!)
+ end
+ alias_method :form_remote_for, :remote_form_for
+
+ # Returns a form tag that will allow the unobtrusive JavaScript drivers to submit the
+ # form dynamically. The default JavaScript driver behaviour is an XMLHttpRequest
+ # in the background instead of the regular POST arrangement. Even though it's using
+ # JavaScript to serialize the form elements, the form submission will work just like
+ # a regular submission as viewed by the receiving side (all elements available in
+ # <tt>params</tt>). The options for specifying the target with <tt>:url</tt> and
+ # defining callbacks is the same as +link_to_remote+.
+ #
+ # A "fall-through" target for browsers that doesn't do JavaScript can be
+ # specified with the <tt>:action</tt>/<tt>:method</tt> options on <tt>:html</tt>.
+ #
+ # Example:
+ #
+ # # Generates:
+ # # <form action="http://www.example.com/fast"
+ # # method="post"
+ # # data-remote="true"
+ # # data-update-success="glass_of_beer"></form>
+ # #
+ # form_remote_tag(:update => "glass_of_beer", :url => { :action => :fast }) {}
+ #
+ # The Hash passed to the <tt>:html</tt> key is equivalent to the options (2nd)
+ # argument in the FormTagHelper.form_tag method.
+ #
+ # By default the fall-through action is the same as the one specified in
+ # the <tt>:url</tt> (and the default method is <tt>:post</tt>).
+ #
+ # form_remote_tag also takes a block, like form_tag:
+ # # Generates:
+ # # <form action='/posts'
+ # # method='post'
+ # # data-remote='true'>
+ # # <input name="commit" type="submit" value="Save" />
+ # # </form>
+ # #
+ # <% form_remote_tag :url => '/posts' do -%>
+ # <%= submit_tag 'Save' %>
+ # <% end -%>
+ #
+ # # Generates:
+ # # <form action="http://www.example.com/fast"
+ # # method="post"
+ # # data-remote="true"
+ # # data-update-success="glass_of_beer">Hello world!</form>
+ # #
+ # <% form_remote_tag(:update => "glass_of_beer", :url => { :action => :fast }) do -%>
+ # "Hello world!"
+ # <% end -%>
+ #
+ def form_remote_tag(options = {}, &block)
+ html_options = options.delete(:callbacks)
+
+ attributes = {}
+ attributes.merge!(extract_remote_attributes!(options))
+ attributes.merge!(html_options) if html_options
+ attributes.merge!(options)
+ attributes.delete(:builder)
+
+ form_tag(attributes.delete(:action) || attributes.delete("data-url"), attributes, &block)
+ end
+
+ # Returns a link that will allow unobtrusive JavaScript to dynamical adjust its
+ # behaviour. The default behaviour is an XMLHttpRequest in the background instead
+ # of the regular GET arrangement. The result of that request can then be inserted
+ # into a DOM object whose id can be specified with <tt>options[:update]</tt>. Usually,
+ # the result would be a partial prepared by the controller with render :partial.
+ #
+ # Examples:
+ #
+ # # Generates:
+ # # <a href="#"
+ # # data-remote="true"
+ # # data-url="http://www.example.com/whatnot"
+ # # data-method="delete"
+ # # rel="nofollow">Remove Author</a>
+ # #
+ # link_to_remote("Remove Author", { :url => { :action => "whatnot" },
+ # :method => "delete"})
+ #
+ #
+ # You can override the generated HTML options by specifying a hash in
+ # <tt>options[:html]</tt>.
+ #
+ # # Generates:
+ # # <a class="fine"
+ # # href="#"
+ # # data-remote="true"
+ # # data-url="http://www.example.com/whatnot"
+ # # data-method="delete"
+ # # rel="nofollow">Remove Author</a>
+ # #
+ # link_to_remote("Remove Author", { :url => { :action => "whatnot" },
+ # :method => "delete",
+ # :html => { :class => "fine" }})
+ #
+ #
+ # You can also specify a hash for <tt>options[:update]</tt> to allow for
+ # easy redirection of output to an other DOM element if a server-side
+ # error occurs:
+ #
+ # Example:
+ # # Generates:
+ # #
+ # # <a href="#"
+ # # data-url="http://www.example.com/destroy"
+ # # data-update-success="posts"
+ # # data-update-failure="error"
+ # # data-remote="true">Delete this Post</a>'
+ # #
+ # link_to_remote "Delete this post",
+ # :url => { :action => "destroy"},
+ # :update => { :success => "posts", :failure => "error" }
+ #
+ # Optionally, you can use the <tt>options[:position]</tt> parameter to
+ # influence how the target DOM element is updated. It must be one of
+ # <tt>:before</tt>, <tt>:top</tt>, <tt>:bottom</tt>, or <tt>:after</tt>.
+ #
+ # Example:
+ # # Generates:
+ # # <a href="#"
+ # # data-remote="true"
+ # # data-url="http://www.example.com/whatnot"
+ # # data-update-position="bottom">Remove Author</a>
+ # #
+ # link_to_remote("Remove Author", :url => { :action => "whatnot" }, :position => :bottom)
+ #
+ #
+ # The method used is by default POST. You can also specify GET or you
+ # can simulate PUT or DELETE over POST. All specified with <tt>options[:method]</tt>
+ #
+ # Example:
+ # # Generates:
+ # # <a href='#'
+ # # data-url='/person/4'
+ # # rel='nofollow'
+ # # data-remote='true'
+ # # data-method='delete'>Destroy</a>
+ # #
+ # link_to_remote "Destroy", :url => person_url(:id => person), :method => :delete
+ #
+ # By default, these remote requests are processed asynchronous during
+ # which various JavaScript callbacks can be triggered (for progress
+ # indicators and the likes). All callbacks get access to the
+ # <tt>request</tt> object, which holds the underlying XMLHttpRequest.
+ #
+ # To access the server response, use <tt>request.responseText</tt>, to
+ # find out the HTTP status, use <tt>request.status</tt>.
+ #
+ # Example:
+ # # Generates:
+ # #
+ # # <a href='#'
+ # # data-url='http://www.example.com/undo?n=5'
+ # # data-oncomplete='undoRequestCompleted(request)'
+ # # data-remote='true'>undo</a>
+ # #
+ # link_to_remote "undo",
+ # :url => { :controller => "words", :action => "undo", :n => word_counter },
+ # :complete => "undoRequestCompleted(request)"
+ #
+ # The callbacks that may be specified are (in order):
+ #
+ # <tt>:loading</tt>:: Called when the remote document is being
+ # loaded with data by the browser.
+ # <tt>:loaded</tt>:: Called when the browser has finished loading
+ # the remote document.
+ # <tt>:interactive</tt>:: Called when the user can interact with the
+ # remote document, even though it has not
+ # finished loading.
+ # <tt>:success</tt>:: Called when the XMLHttpRequest is completed,
+ # and the HTTP status code is in the 2XX range.
+ # <tt>:failure</tt>:: Called when the XMLHttpRequest is completed,
+ # and the HTTP status code is not in the 2XX
+ # range.
+ # <tt>:complete</tt>:: Called when the XMLHttpRequest is complete
+ # (fires after success/failure if they are
+ # present).
+ #
+ # You can further refine <tt>:success</tt> and <tt>:failure</tt> by
+ # adding additional callbacks for specific status codes.
+ #
+ # Example:
+ #
+ # # Generates:
+ # # <a href='/testing/action'
+ # # date-remote='true'
+ # # data-failure="function(request){alert('HTTP Error '+ request.status +'+!');return false}"
+ # # data-404="function(request){alert('Not found...? Wrong URL...?')}"> Hello</a>
+ # #
+ # link_to_remote word,
+ # :url => { :action => "action" },
+ # 404 => "alert('Not found...? Wrong URL...?')",
+ # :failure => "alert('HTTP Error ' + request.status + '!')"
+ #
+ # A status code callback overrides the success/failure handlers if
+ # present.
+ #
+ # If you for some reason or another need synchronous processing (that'll
+ # block the browser while the request is happening), you can specify
+ # <tt>options[:type] = :synchronous</tt>.
+ #
+ # You can customize further browser side call logic by passing in
+ # JavaScript code snippets via some optional parameters. In their order
+ # of use these are:
+ #
+ # <tt>:confirm</tt>:: Adds confirmation dialog.
+ # <tt>:condition</tt>:: Perform remote request conditionally
+ # by this expression. Use this to
+ # describe browser-side conditions when
+ # request should not be initiated.
+ # <tt>:before</tt>:: Called before request is initiated.
+ # <tt>:after</tt>:: Called immediately after request was
+ # initiated and before <tt>:loading</tt>.
+ # <tt>:submit</tt>:: Specifies the DOM element ID that's used
+ # as the parent of the form elements. By
+ # default this is the current form, but
+ # it could just as well be the ID of a
+ # table row or any other DOM element.
+ # <tt>:with</tt>:: A JavaScript expression specifying
+ # the parameters for the XMLHttpRequest.
+ # Any expressions should return a valid
+ # URL query string.
+ #
+ # Example:
+ #
+ # :with => "'name=' + $('name').value"
+ #
+ # You can generate a link that uses the UJS drivers in the general case, while
+ # degrading gracefully to plain link behavior in the absence of
+ # JavaScript by setting <tt>html_options[:href]</tt> to an alternate URL.
+ # Note the extra curly braces around the <tt>options</tt> hash separate
+ # it as the second parameter from <tt>html_options</tt>, the third.
+ #
+ # Example:
+ #
+ # # Generates:
+ # # <a href='/posts/1'
+ # # rel='nofollow'
+ # # data-remote='true'
+ # # data-method='delete'> Delete this post</a>
+ # #
+ # link_to_remote "Delete this post",
+ # { :update => "posts", :url => { :action => "destroy", :id => post.id } }
+ #
+ def link_to_remote(name, options, html_options = {})
+ attributes = {}
+
+ attributes.merge!(:rel => "nofollow") if options[:method] && options[:method].to_s.downcase == "delete"
+ attributes.merge!(extract_remote_attributes!(options))
- url = url_for(url) if url.is_a?(Hash)
- link_to(name, url, html)
+ if confirm = options.delete(:confirm)
+ add_confirm_to_attributes!(attributes, confirm)
+ end
+
+ attributes.merge!(html_options)
+ href = html_options[:href].nil? ? "#" : html_options[:href]
+ attributes.merge!(:href => href)
+
+ content_tag(:a, name, attributes)
+ end
+
+ # Returns an input of type button, which allows the unobtrusive JavaScript driver
+ # to dynamically adjust its behaviour. The default driver behaviour is to call a
+ # remote action via XMLHttpRequest in the background.
+ # The options for specifying the target with :url and defining callbacks is the same
+ # as link_to_remote.
+ #
+ # Example:
+ #
+ # # Generates:
+ # # <input class="fine"
+ # # type="button"
+ # # value="Remote outpost"
+ # # data-remote="true"
+ # # data-url="http://www.example.com/whatnot" />
+ # #
+ # button_to_remote("Remote outpost", { :url => { :action => "whatnot" }}, { :class => "fine" })
+ #
+ def button_to_remote(name, options = {}, html_options = {})
+ attributes = html_options.merge!(:type => "button", :value => name)
+
+ if confirm = options.delete(:confirm)
+ add_confirm_to_attributes!(attributes, confirm)
+ end
+
+ if disable_with = options.delete(:disable_with)
+ add_disable_with_to_attributes!(attributes, disable_with)
+ end
+
+ attributes.merge!(extract_remote_attributes!(options))
+
+ tag(:input, attributes)
+ end
+
+ # Returns an input tag of type button, with the element name of +name+ and a value (i.e., display text)
+ # of +value+ which will allow the unobtrusive JavaScript driver to dynamically adjust its behaviour
+ # The default behaviour is to call a remote action via XMLHttpRequest in the background.
+ #
+ # request that reloads the page.
+ #
+ # # Create a button that submits to the create action
+ # #
+ # # Generates:
+ # # <input name='create_btn'
+ # # type='button'
+ # # value='Create'
+ # # data-remote='true'
+ # # data-url='/create' />
+ # #
+ # <%= submit_to_remote 'create_btn', 'Create', :url => { :action => 'create' } %>
+ #
+ # # Submit to the remote action update and update the DIV succeed or fail based
+ # # on the success or failure of the request
+ # #
+ # # Generates:
+ # # <input name='update_btn'
+ # # type='button'
+ # # value='Update'
+ # # date-remote-submit='true'
+ # # data-url='/testing/update'
+ # # data-success='succeed'
+ # # data-failure='fail' />
+ # #
+ # <%= submit_to_remote 'update_btn', 'Update', :url => { :action => 'update' },
+ # :update => { :success => "succeed", :failure => "fail" }
+ #
+ # <tt>options</tt> argument is the same as in form_remote_tag.
+ def submit_to_remote(name, value, options = {})
+ html_options = options.delete(:html) || {}
+ html_options.merge!(:name => name, :value => value, :type => "button")
+
+ attributes = extract_remote_attributes!(options)
+ attributes.merge!(html_options)
+ attributes["data-remote-submit"] = true
+ attributes.delete("data-remote")
+
+ tag(:input, attributes)
+ end
+
+ # Periodically provides the UJS driver with the information to call the specified
+ # url (<tt>options[:url]</tt>) every <tt>options[:frequency]</tt> seconds (default is 10). Usually used to
+ # update a specified div (<tt>options[:update]</tt>) with the results
+ # of the remote call. The options for specifying the target with <tt>:url</tt>
+ # and defining callbacks is the same as link_to_remote.
+ # Examples:
+ # # Call get_averages and put its results in 'avg' every 10 seconds
+ # # Generates:
+ # # <script data-periodical='true'
+ # # data-url='/get_averages'
+ # # type='application/json'
+ # # data-update-success='avg'
+ # # data-frequency='10'></script>
+ # #
+ # periodically_call_remote(:url => { :action => 'get_averages' }, :update => 'avg')
+ #
+ # # Call invoice every 10 seconds with the id of the customer
+ # # If it succeeds, update the invoice DIV; if it fails, update the error DIV
+ # # Generates:
+ # # <script data-periodical='true'
+ # # data-url='/invoice/1'
+ # # type='application/json'
+ # # data-update-success='invoice'
+ # # data-update-failure='error'
+ # # data-frequency='10'></script>"
+ # #
+ # periodically_call_remote(:url => { :action => 'invoice', :id => 1 },
+ # :update => { :success => "invoice", :failure => "error" }
+ #
+ # # Call update every 20 seconds and update the new_block DIV
+ # # Generates:
+ # # <script data-periodical='true'
+ # # data-url='update'
+ # # type='application/json'
+ # # data-update-success='news_block'
+ # # data-frequency='20'></script>
+ # #
+ # periodically_call_remote(:url => 'update', :frequency => '20', :update => 'news_block')
+ #
+ def periodically_call_remote(options = {})
+ attributes = extract_observer_attributes!(options)
+ attributes["data-periodical"] = true
+ attributes["data-frequency"] ||= 10
+
+ # periodically_call_remote does not need data-observe=true
+ attributes.delete('data-observe')
+
+ script_decorator(attributes).html_safe!
+ end
+
+ # Observes the field with the DOM ID specified by +field_id+ and calls a
+ # callback when its contents have changed. The default callback is an
+ # Ajax call. By default the value of the observed field is sent as a
+ # parameter with the Ajax call.
+ #
+ # Example:
+ # # Generates:
+ # # "<script type='text/javascript'
+ # # data-observe='true'
+ # # data-observed='suggest'
+ # # data-frequency='0.25'
+ # # type='application/json'
+ # # data-url='/find_suggestion'
+ # # data-update-success='suggest'
+ # # data-with='q'></script>"
+ # #
+ # <%= observe_field :suggest, :url => { :action => :find_suggestion },
+ # :frequency => 0.25,
+ # :update => :suggest,
+ # :with => 'q'
+ # %>
+ #
+ # Required +options+ are either of:
+ # <tt>:url</tt>:: +url_for+-style options for the action to call
+ # when the field has changed.
+ # <tt>:function</tt>:: Instead of making a remote call to a URL, you
+ # can specify javascript code to be called instead.
+ # Note that the value of this option is used as the
+ # *body* of the javascript function, a function definition
+ # with parameters named element and value will be generated for you
+ # for example:
+ # observe_field("glass", :frequency => 1, :function => "alert('Element changed')")
+ # will generate:
+ # new Form.Element.Observer('glass', 1, function(element, value) {alert('Element changed')})
+ # The element parameter is the DOM element being observed, and the value is its value at the
+ # time the observer is triggered.
+ #
+ # Additional options are:
+ # <tt>:frequency</tt>:: The frequency (in seconds) at which changes to
+ # this field will be detected. Not setting this
+ # option at all or to a value equal to or less than
+ # zero will use event based observation instead of
+ # time based observation.
+ # <tt>:update</tt>:: Specifies the DOM ID of the element whose
+ # innerHTML should be updated with the
+ # XMLHttpRequest response text.
+ # <tt>:with</tt>:: A JavaScript expression specifying the parameters
+ # for the XMLHttpRequest. The default is to send the
+ # key and value of the observed field. Any custom
+ # expressions should return a valid URL query string.
+ # The value of the field is stored in the JavaScript
+ # variable +value+.
+ #
+ # Examples
+ #
+ # :with => "'my_custom_key=' + value"
+ # :with => "'person[name]=' + prompt('New name')"
+ # :with => "Form.Element.serialize('other-field')"
+ #
+ # Finally
+ # :with => 'name'
+ # is shorthand for
+ # :with => "'name=' + value"
+ # This essentially just changes the key of the parameter.
+ #
+ # Additionally, you may specify any of the options documented in the
+ # <em>Common options</em> section at the top of this document.
+ #
+ # Example:
+ #
+ # # Sends params: {:title => 'Title of the book'} when the book_title input
+ # # field is changed.
+ # observe_field 'book_title',
+ # :url => 'http://example.com/books/edit/1',
+ # :with => 'title'
+ #
+ #
+ def observe_field(name, options = {})
+ html_options = options.delete(:callbacks)
+
+ options[:observed] = name
+ attributes = extract_observer_attributes!(options)
+ attributes.merge!(html_options) if html_options
+
+ script_decorator(attributes).html_safe!
+ end
+
+ # Observes the form with the DOM ID specified by +form_id+ and calls a
+ # callback when its contents have changed. The default callback is an
+ # Ajax call. By default all fields of the observed field are sent as
+ # parameters with the Ajax call.
+ #
+ # The +options+ for +observe_form+ are the same as the options for
+ # +observe_field+. The JavaScript variable +value+ available to the
+ # <tt>:with</tt> option is set to the serialized form by default.
+ def observe_form(name, options = {})
+ html_options = options.delete(:callbacks)
+
+ options[:observed] = name
+ attributes = extract_observer_attributes!(options)
+ attributes.merge!(html_options) if html_options
+
+ script_decorator(attributes).html_safe!
+ end
+
+ def script_decorator(options)
+ attributes = %w(type="application/json")
+ attributes += options.map{|k, v| k + '="' + v.to_s + '"'}
+ "<script " + attributes.join(" ") + "></script>"
+ end
+
+ private
+
+ def extract_remote_attributes!(options)
+ attributes = options.delete(:html) || {}
+
+ attributes.merge!(extract_update_attributes!(options))
+ attributes.merge!(extract_request_attributes!(options))
+ attributes["data-remote"] = true
+
+ if submit = options.delete(:submit)
+ attributes["data-submit"] = submit
+ end
+
+ attributes
+ end
+
+ def extract_request_attributes!(options)
+ attributes = {}
+ if method = options.delete(:method)
+ attributes["data-method"] = method.to_s
+ end
+
+ if type = options.delete(:type)
+ attributes["data-remote-type"] = type.to_s
+ end
+
+ url_options = options.delete(:url)
+ url_options = url_options.merge(:escape => false) if url_options.is_a?(Hash)
+ attributes["data-url"] = escape_javascript(url_for(url_options)) if url_options
+
+ purge_unused_attributes!(attributes)
+ end
+
+ def extract_update_attributes!(options)
+ attributes = {}
+ update = options.delete(:update)
+ if update.is_a?(Hash)
+ attributes["data-update-success"] = update[:success]
+ attributes["data-update-failure"] = update[:failure]
+ else
+ attributes["data-update-success"] = update
+ end
+
+ if position = options.delete(:position)
+ attributes["data-update-position"] = position.to_s
+ end
+
+ purge_unused_attributes!(attributes)
+ end
+
+ def extract_observer_attributes!(options)
+ callback = options.delete(:function)
+ frequency = options.delete(:frequency) || 10
+
+
+ attributes = extract_remote_attributes!(options)
+ attributes["data-observe"] = true
+ attributes["data-observed"] = options.delete(:observed)
+ attributes["data-onobserve"] = callback if callback
+ attributes["data-frequency"] = frequency if frequency && frequency.to_f != 0
+ attributes.delete("data-remote")
+
+ purge_unused_attributes!(attributes)
+ end
+
+ def purge_unused_attributes!(attributes)
+ attributes.delete_if {|key, value| value.nil? }
+ attributes
+ end
+ end
+
+ # TODO: All evaled goes here per wycat
+ module AjaxHelperCompat
+ include AjaxHelper
+
+ def link_to_remote(name, options, html_options = {})
+ set_callbacks(options, html_options)
+ set_with_and_condition_attributes(options, html_options)
+ super
end
def button_to_remote(name, options = {}, html_options = {})
- url = options.delete(:url)
- url = url_for(url) if url.is_a?(Hash)
-
- html_options.merge!(:type => "button", :value => name,
- :"data-url" => url)
-
- tag(:input, html_options)
+ set_callbacks(options, html_options)
+ set_with_and_condition_attributes(options, html_options)
+ super
+ end
+
+ def form_remote_tag(options, &block)
+ html = {}
+ set_callbacks(options, html)
+ set_with_and_condition_attributes(options, html)
+ options.merge!(:callbacks => html)
+ super
+ end
+
+ def observe_field(name, options = {})
+ html = {}
+ set_with_and_condition_attributes(options, html)
+ options.merge!(:callbacks => html)
+ super
end
- module Rails2Compatibility
+ def observe_form(name, options = {})
+ html = {}
+ set_with_and_condition_attributes(options, html)
+ options.merge!(:callbacks => html)
+ super
+ end
+
+ private
def set_callbacks(options, html)
- [:complete, :failure, :success, :interactive, :loaded, :loading].each do |type|
- html["data-#{type}-code"] = options.delete(type.to_sym)
+ [:before, :after, :uninitialized, :complete, :failure, :success, :interactive, :loaded, :loading].each do |type|
+ html["data-on#{type}"] = options.delete(type.to_sym)
end
options.each do |option, value|
if option.is_a?(Integer)
- html["data-#{option}-code"] = options.delete(option)
+ html["data-on#{option}"] = options.delete(option)
end
end
end
-
- def link_to_remote(name, url, options = nil)
- if !options && url.is_a?(Hash) && url.key?(:url)
- url, options = url.delete(:url), url
+
+ def set_with_and_condition_attributes(options, html)
+ if with = options.delete(:with)
+ html["data-with"] = with
+ end
+
+ if condition = options.delete(:condition)
+ html["data-condition"] = condition
end
-
- set_callbacks(options, options[:html] ||= {})
-
- super
- end
-
- def button_to_remote(name, options = {}, html_options = {})
- set_callbacks(options, html_options)
- super
end
- end
-
end
end
-end \ No newline at end of file
+end
diff --git a/actionpack/lib/action_view/helpers/form_helper.rb b/actionpack/lib/action_view/helpers/form_helper.rb
index 157deebe40..b81925c7e7 100644
--- a/actionpack/lib/action_view/helpers/form_helper.rb
+++ b/actionpack/lib/action_view/helpers/form_helper.rb
@@ -262,23 +262,8 @@ module ActionView
# FormTagHelper#form_tag.
def form_for(record_or_name_or_array, *args, &proc)
raise ArgumentError, "Missing block" unless block_given?
-
options = args.extract_options!
-
- case record_or_name_or_array
- when String, Symbol
- object_name = record_or_name_or_array
- when Array
- object = record_or_name_or_array.last
- object_name = ActionController::RecordIdentifier.singular_class_name(object)
- apply_form_for_options!(record_or_name_or_array, options)
- args.unshift object
- else
- object = record_or_name_or_array
- object_name = ActionController::RecordIdentifier.singular_class_name(object)
- apply_form_for_options!([object], options)
- args.unshift object
- end
+ object_name = extract_object_name_for_form!(args, options, record_or_name_or_array)
concat(form_tag(options.delete(:url) || {}, options.delete(:html) || {}))
fields_for(object_name, *(args << options), &proc)
@@ -742,6 +727,25 @@ module ActionView
def radio_button(object_name, method, tag_value, options = {})
InstanceTag.new(object_name, method, self, options.delete(:object)).to_radio_button_tag(tag_value, options)
end
+
+ private
+ def extract_object_name_for_form!(args, options, record_or_name_or_array)
+ case record_or_name_or_array
+ when String, Symbol
+ object_name = record_or_name_or_array
+ when Array
+ object = record_or_name_or_array.last
+ object_name = ActionController::RecordIdentifier.singular_class_name(object)
+ apply_form_for_options!(record_or_name_or_array, options)
+ args.unshift object
+ else
+ object = record_or_name_or_array
+ object_name = ActionController::RecordIdentifier.singular_class_name(object)
+ apply_form_for_options!([object], options)
+ args.unshift object
+ end
+ object_name
+ end
end
module InstanceTagMethods #:nodoc:
diff --git a/actionpack/lib/action_view/helpers/form_tag_helper.rb b/actionpack/lib/action_view/helpers/form_tag_helper.rb
index 048bedc7ba..ebce5c1513 100644
--- a/actionpack/lib/action_view/helpers/form_tag_helper.rb
+++ b/actionpack/lib/action_view/helpers/form_tag_helper.rb
@@ -352,33 +352,24 @@ module ActionView
# # => <input disabled="disabled" name="commit" type="submit" value="Save edits" />
#
# submit_tag "Complete sale", :disable_with => "Please wait..."
- # # => <input name="commit" onclick="this.disabled=true;this.value='Please wait...';this.form.submit();"
+ # # => <input name="commit" data-disable-with="Please wait..."
# # type="submit" value="Complete sale" />
#
# submit_tag nil, :class => "form_submit"
# # => <input class="form_submit" name="commit" type="submit" />
#
# submit_tag "Edit", :disable_with => "Editing...", :class => "edit-button"
- # # => <input class="edit-button" onclick="this.disabled=true;this.value='Editing...';this.form.submit();"
+ # # => <input class="edit-button" data-disable-with="Editing..."
# # name="commit" type="submit" value="Edit" />
def submit_tag(value = "Save changes", options = {})
options.stringify_keys!
if disable_with = options.delete("disable_with")
- disable_with = "this.value='#{disable_with}'"
- disable_with << ";#{options.delete('onclick')}" if options['onclick']
-
- options["onclick"] = "if (window.hiddenCommit) { window.hiddenCommit.setAttribute('value', this.value); }"
- options["onclick"] << "else { hiddenCommit = document.createElement('input');hiddenCommit.type = 'hidden';"
- options["onclick"] << "hiddenCommit.value = this.value;hiddenCommit.name = this.name;this.form.appendChild(hiddenCommit); }"
- options["onclick"] << "this.setAttribute('originalValue', this.value);this.disabled = true;#{disable_with};"
- options["onclick"] << "result = (this.form.onsubmit ? (this.form.onsubmit() ? this.form.submit() : false) : this.form.submit());"
- options["onclick"] << "if (result == false) { this.value = this.getAttribute('originalValue');this.disabled = false; }return result;"
+ add_disable_with_to_attributes!(options, disable_with)
end
if confirm = options.delete("confirm")
- options["onclick"] ||= 'return true;'
- options["onclick"] = "if (!#{confirm_javascript_function(confirm)}) return false; #{options['onclick']}"
+ add_confirm_to_attributes!(options, confirm)
end
tag :input, { "type" => "submit", "name" => "commit", "value" => value }.update(options.stringify_keys)
@@ -411,8 +402,7 @@ module ActionView
options.stringify_keys!
if confirm = options.delete("confirm")
- options["onclick"] ||= ''
- options["onclick"] += "return #{confirm_javascript_function(confirm)};"
+ add_confirm_to_attributes!(options, confirm)
end
tag :input, { "type" => "image", "src" => path_to_image(source) }.update(options.stringify_keys)
diff --git a/actionpack/lib/action_view/helpers/javascript_helper.rb b/actionpack/lib/action_view/helpers/javascript_helper.rb
index 8f64acf102..ee6481b86d 100644
--- a/actionpack/lib/action_view/helpers/javascript_helper.rb
+++ b/actionpack/lib/action_view/helpers/javascript_helper.rb
@@ -39,7 +39,7 @@ module ActionView
JAVASCRIPT_PATH = File.join(File.dirname(__FILE__), 'javascripts')
end
- include PrototypeHelper
+ include AjaxHelperCompat
# Returns a link of the given +name+ that will trigger a JavaScript +function+ using the
# onclick handler and return false after the fact.
@@ -188,6 +188,48 @@ module ActionView
end
protected
+ def convert_options_to_javascript!(html_options, url = '')
+ confirm, popup = html_options.delete("confirm"), html_options.delete("popup")
+
+ method, href = html_options.delete("method"), html_options['href']
+
+ if popup && method
+ raise ActionView::ActionViewError, "You can't use :popup and :method in the same link"
+ elsif confirm && popup
+ add_confirm_to_attributes!(html_options, confirm)
+ html_options["data-popup"] = popup_attributes(popup)
+ elsif confirm && method
+ add_confirm_to_attributes!(html_options, confirm)
+ add_method_to_attributes!(html_options, method, url)
+ elsif confirm
+ add_confirm_to_attributes!(html_options, confirm)
+ elsif method
+ add_method_to_attributes!(html_options, method, url)
+ elsif popup
+ html_options["data-popup"] = popup_attributes(popup)
+ end
+ end
+
+ def add_confirm_to_attributes!(html_options, confirm)
+ html_options["data-confirm"] = confirm if confirm
+ end
+
+ def add_method_to_attributes!(html_options, method, url = nil)
+ html_options["rel"] = "nofollow" if method.to_s.downcase == "delete"
+ html_options["data-method"] = method
+ if url.size > 0
+ html_options["data-url"] = url
+ end
+ end
+
+ def add_disable_with_to_attributes!(html_options, disable_with)
+ html_options["data-disable-with"] = disable_with if disable_with
+ end
+
+ def popup_attributes(popup)
+ popup.is_a?(Array) ? "{title: '#{popup.first}', options: '#{popup.last}'}" : "true"
+ end
+
def options_for_javascript(options)
if options.empty?
'{}'
diff --git a/actionpack/lib/action_view/helpers/prototype_helper.rb b/actionpack/lib/action_view/helpers/prototype_helper.rb
index ff7bc3b34e..d861810f19 100644
--- a/actionpack/lib/action_view/helpers/prototype_helper.rb
+++ b/actionpack/lib/action_view/helpers/prototype_helper.rb
@@ -1,7 +1,7 @@
require 'set'
require 'active_support/json'
-require 'active_support/core_ext/object/extending'
require 'active_support/core_ext/object/returning'
+require 'action_view/helpers/scriptaculous_helper'
module ActionView
module Helpers
@@ -28,40 +28,6 @@ module ActionView
# ActionView::Helpers::JavaScriptHelper for more information on including
# this and other JavaScript files in your Rails templates.)
#
- # Now you're ready to call a remote action either through a link...
- #
- # link_to_remote "Add to cart",
- # :url => { :action => "add", :id => product.id },
- # :update => { :success => "cart", :failure => "error" }
- #
- # ...through a form...
- #
- # <% form_remote_tag :url => '/shipping' do -%>
- # <div><%= submit_tag 'Recalculate Shipping' %></div>
- # <% end -%>
- #
- # ...periodically...
- #
- # periodically_call_remote(:url => 'update', :frequency => '5', :update => 'ticker')
- #
- # ...or through an observer (i.e., a form or field that is observed and calls a remote
- # action when changed).
- #
- # <%= observe_field(:searchbox,
- # :url => { :action => :live_search }),
- # :frequency => 0.5,
- # :update => :hits,
- # :with => 'query'
- # %>
- #
- # As you can see, there are numerous ways to use Prototype's Ajax functions (and actually more than
- # are listed here); check out the documentation for each method to find out more about its usage and options.
- #
- # === Common Options
- # See link_to_remote for documentation of options common to all Ajax
- # helpers; any of the options specified by link_to_remote can be used
- # by the other helpers.
- #
# == Designing your Rails actions for Ajax
# When building your action handlers (that is, the Rails actions that receive your background requests), it's
# important to remember a few things. First, whatever your action would normally return to the browser, it will
@@ -108,6 +74,8 @@ module ActionView
# See JavaScriptGenerator for information on updating multiple elements
# on the page in an Ajax response.
module PrototypeHelper
+ include ScriptaculousHelper
+
unless const_defined? :CALLBACKS
CALLBACKS = Set.new([ :create, :uninitialized, :loading, :loaded,
:interactive, :complete, :failure, :success ] +
@@ -117,325 +85,6 @@ module ActionView
:form, :with, :update, :script, :type ]).merge(CALLBACKS)
end
- # Returns a link to a remote action defined by <tt>options[:url]</tt>
- # (using the url_for format) that's called in the background using
- # XMLHttpRequest. The result of that request can then be inserted into a
- # DOM object whose id can be specified with <tt>options[:update]</tt>.
- # Usually, the result would be a partial prepared by the controller with
- # render :partial.
- #
- # Examples:
- # # Generates: <a href="#" onclick="new Ajax.Updater('posts', '/blog/destroy/3', {asynchronous:true, evalScripts:true});
- # # return false;">Delete this post</a>
- # link_to_remote "Delete this post", :update => "posts",
- # :url => { :action => "destroy", :id => post.id }
- #
- # # Generates: <a href="#" onclick="new Ajax.Updater('emails', '/mail/list_emails', {asynchronous:true, evalScripts:true});
- # # return false;"><img alt="Refresh" src="/images/refresh.png?" /></a>
- # link_to_remote(image_tag("refresh"), :update => "emails",
- # :url => { :action => "list_emails" })
- #
- # You can override the generated HTML options by specifying a hash in
- # <tt>options[:html]</tt>.
- #
- # link_to_remote "Delete this post", :update => "posts",
- # :url => post_url(@post), :method => :delete,
- # :html => { :class => "destructive" }
- #
- # You can also specify a hash for <tt>options[:update]</tt> to allow for
- # easy redirection of output to an other DOM element if a server-side
- # error occurs:
- #
- # Example:
- # # Generates: <a href="#" onclick="new Ajax.Updater({success:'posts',failure:'error'}, '/blog/destroy/5',
- # # {asynchronous:true, evalScripts:true}); return false;">Delete this post</a>
- # link_to_remote "Delete this post",
- # :url => { :action => "destroy", :id => post.id },
- # :update => { :success => "posts", :failure => "error" }
- #
- # Optionally, you can use the <tt>options[:position]</tt> parameter to
- # influence how the target DOM element is updated. It must be one of
- # <tt>:before</tt>, <tt>:top</tt>, <tt>:bottom</tt>, or <tt>:after</tt>.
- #
- # The method used is by default POST. You can also specify GET or you
- # can simulate PUT or DELETE over POST. All specified with <tt>options[:method]</tt>
- #
- # Example:
- # # Generates: <a href="#" onclick="new Ajax.Request('/person/4', {asynchronous:true, evalScripts:true, method:'delete'});
- # # return false;">Destroy</a>
- # link_to_remote "Destroy", :url => person_url(:id => person), :method => :delete
- #
- # By default, these remote requests are processed asynchronous during
- # which various JavaScript callbacks can be triggered (for progress
- # indicators and the likes). All callbacks get access to the
- # <tt>request</tt> object, which holds the underlying XMLHttpRequest.
- #
- # To access the server response, use <tt>request.responseText</tt>, to
- # find out the HTTP status, use <tt>request.status</tt>.
- #
- # Example:
- # # Generates: <a href="#" onclick="new Ajax.Request('/words/undo?n=33', {asynchronous:true, evalScripts:true,
- # # onComplete:function(request){undoRequestCompleted(request)}}); return false;">hello</a>
- # word = 'hello'
- # link_to_remote word,
- # :url => { :action => "undo", :n => word_counter },
- # :complete => "undoRequestCompleted(request)"
- #
- # The callbacks that may be specified are (in order):
- #
- # <tt>:loading</tt>:: Called when the remote document is being
- # loaded with data by the browser.
- # <tt>:loaded</tt>:: Called when the browser has finished loading
- # the remote document.
- # <tt>:interactive</tt>:: Called when the user can interact with the
- # remote document, even though it has not
- # finished loading.
- # <tt>:success</tt>:: Called when the XMLHttpRequest is completed,
- # and the HTTP status code is in the 2XX range.
- # <tt>:failure</tt>:: Called when the XMLHttpRequest is completed,
- # and the HTTP status code is not in the 2XX
- # range.
- # <tt>:complete</tt>:: Called when the XMLHttpRequest is complete
- # (fires after success/failure if they are
- # present).
- #
- # You can further refine <tt>:success</tt> and <tt>:failure</tt> by
- # adding additional callbacks for specific status codes.
- #
- # Example:
- # # Generates: <a href="#" onclick="new Ajax.Request('/testing/action', {asynchronous:true, evalScripts:true,
- # # on404:function(request){alert('Not found...? Wrong URL...?')},
- # # onFailure:function(request){alert('HTTP Error ' + request.status + '!')}}); return false;">hello</a>
- # link_to_remote word,
- # :url => { :action => "action" },
- # 404 => "alert('Not found...? Wrong URL...?')",
- # :failure => "alert('HTTP Error ' + request.status + '!')"
- #
- # A status code callback overrides the success/failure handlers if
- # present.
- #
- # If you for some reason or another need synchronous processing (that'll
- # block the browser while the request is happening), you can specify
- # <tt>options[:type] = :synchronous</tt>.
- #
- # You can customize further browser side call logic by passing in
- # JavaScript code snippets via some optional parameters. In their order
- # of use these are:
- #
- # <tt>:confirm</tt>:: Adds confirmation dialog.
- # <tt>:condition</tt>:: Perform remote request conditionally
- # by this expression. Use this to
- # describe browser-side conditions when
- # request should not be initiated.
- # <tt>:before</tt>:: Called before request is initiated.
- # <tt>:after</tt>:: Called immediately after request was
- # initiated and before <tt>:loading</tt>.
- # <tt>:submit</tt>:: Specifies the DOM element ID that's used
- # as the parent of the form elements. By
- # default this is the current form, but
- # it could just as well be the ID of a
- # table row or any other DOM element.
- # <tt>:with</tt>:: A JavaScript expression specifying
- # the parameters for the XMLHttpRequest.
- # Any expressions should return a valid
- # URL query string.
- #
- # Example:
- #
- # :with => "'name=' + $('name').value"
- #
- # You can generate a link that uses AJAX in the general case, while
- # degrading gracefully to plain link behavior in the absence of
- # JavaScript by setting <tt>html_options[:href]</tt> to an alternate URL.
- # Note the extra curly braces around the <tt>options</tt> hash separate
- # it as the second parameter from <tt>html_options</tt>, the third.
- #
- # Example:
- # link_to_remote "Delete this post",
- # { :update => "posts", :url => { :action => "destroy", :id => post.id } },
- # :href => url_for(:action => "destroy", :id => post.id)
- def link_to_remote(name, options = {}, html_options = nil)
- link_to_function(name, remote_function(options), html_options || options.delete(:html))
- end
-
- # Creates a button with an onclick event which calls a remote action
- # via XMLHttpRequest
- # The options for specifying the target with :url
- # and defining callbacks is the same as link_to_remote.
- def button_to_remote(name, options = {}, html_options = {})
- button_to_function(name, remote_function(options), html_options)
- end
-
- # Periodically calls the specified url (<tt>options[:url]</tt>) every
- # <tt>options[:frequency]</tt> seconds (default is 10). Usually used to
- # update a specified div (<tt>options[:update]</tt>) with the results
- # of the remote call. The options for specifying the target with <tt>:url</tt>
- # and defining callbacks is the same as link_to_remote.
- # Examples:
- # # Call get_averages and put its results in 'avg' every 10 seconds
- # # Generates:
- # # new PeriodicalExecuter(function() {new Ajax.Updater('avg', '/grades/get_averages',
- # # {asynchronous:true, evalScripts:true})}, 10)
- # periodically_call_remote(:url => { :action => 'get_averages' }, :update => 'avg')
- #
- # # Call invoice every 10 seconds with the id of the customer
- # # If it succeeds, update the invoice DIV; if it fails, update the error DIV
- # # Generates:
- # # new PeriodicalExecuter(function() {new Ajax.Updater({success:'invoice',failure:'error'},
- # # '/testing/invoice/16', {asynchronous:true, evalScripts:true})}, 10)
- # periodically_call_remote(:url => { :action => 'invoice', :id => customer.id },
- # :update => { :success => "invoice", :failure => "error" }
- #
- # # Call update every 20 seconds and update the new_block DIV
- # # Generates:
- # # new PeriodicalExecuter(function() {new Ajax.Updater('news_block', 'update', {asynchronous:true, evalScripts:true})}, 20)
- # periodically_call_remote(:url => 'update', :frequency => '20', :update => 'news_block')
- #
- def periodically_call_remote(options = {})
- frequency = options[:frequency] || 10 # every ten seconds by default
- code = "new PeriodicalExecuter(function() {#{remote_function(options)}}, #{frequency})"
- javascript_tag(code)
- end
-
- # Returns a form tag that will submit using XMLHttpRequest in the
- # background instead of the regular reloading POST arrangement. Even
- # though it's using JavaScript to serialize the form elements, the form
- # submission will work just like a regular submission as viewed by the
- # receiving side (all elements available in <tt>params</tt>). The options for
- # specifying the target with <tt>:url</tt> and defining callbacks is the same as
- # +link_to_remote+.
- #
- # A "fall-through" target for browsers that doesn't do JavaScript can be
- # specified with the <tt>:action</tt>/<tt>:method</tt> options on <tt>:html</tt>.
- #
- # Example:
- # # Generates:
- # # <form action="/some/place" method="post" onsubmit="new Ajax.Request('',
- # # {asynchronous:true, evalScripts:true, parameters:Form.serialize(this)}); return false;">
- # form_remote_tag :html => { :action =>
- # url_for(:controller => "some", :action => "place") }
- #
- # The Hash passed to the <tt>:html</tt> key is equivalent to the options (2nd)
- # argument in the FormTagHelper.form_tag method.
- #
- # By default the fall-through action is the same as the one specified in
- # the <tt>:url</tt> (and the default method is <tt>:post</tt>).
- #
- # form_remote_tag also takes a block, like form_tag:
- # # Generates:
- # # <form action="/" method="post" onsubmit="new Ajax.Request('/',
- # # {asynchronous:true, evalScripts:true, parameters:Form.serialize(this)});
- # # return false;"> <div><input name="commit" type="submit" value="Save" /></div>
- # # </form>
- # <% form_remote_tag :url => '/posts' do -%>
- # <div><%= submit_tag 'Save' %></div>
- # <% end -%>
- def form_remote_tag(options = {}, &block)
- options[:form] = true
-
- options[:html] ||= {}
- options[:html][:onsubmit] =
- (options[:html][:onsubmit] ? options[:html][:onsubmit] + "; " : "") +
- "#{remote_function(options)}; return false;"
-
- form_tag(options[:html].delete(:action) || url_for(options[:url]), options[:html], &block)
- end
-
- # Creates a form that will submit using XMLHttpRequest in the background
- # instead of the regular reloading POST arrangement and a scope around a
- # specific resource that is used as a base for questioning about
- # values for the fields.
- #
- # === Resource
- #
- # Example:
- # <% remote_form_for(@post) do |f| %>
- # ...
- # <% end %>
- #
- # This will expand to be the same as:
- #
- # <% remote_form_for :post, @post, :url => post_path(@post), :html => { :method => :put, :class => "edit_post", :id => "edit_post_45" } do |f| %>
- # ...
- # <% end %>
- #
- # === Nested Resource
- #
- # Example:
- # <% remote_form_for([@post, @comment]) do |f| %>
- # ...
- # <% end %>
- #
- # This will expand to be the same as:
- #
- # <% remote_form_for :comment, @comment, :url => post_comment_path(@post, @comment), :html => { :method => :put, :class => "edit_comment", :id => "edit_comment_45" } do |f| %>
- # ...
- # <% end %>
- #
- # If you don't need to attach a form to a resource, then check out form_remote_tag.
- #
- # See FormHelper#form_for for additional semantics.
- def remote_form_for(record_or_name_or_array, *args, &proc)
- options = args.extract_options!
-
- case record_or_name_or_array
- when String, Symbol
- object_name = record_or_name_or_array
- when Array
- object = record_or_name_or_array.last
- object_name = ActionController::RecordIdentifier.singular_class_name(object)
- apply_form_for_options!(record_or_name_or_array, options)
- args.unshift object
- else
- object = record_or_name_or_array
- object_name = ActionController::RecordIdentifier.singular_class_name(record_or_name_or_array)
- apply_form_for_options!(object, options)
- args.unshift object
- end
-
- concat(form_remote_tag(options))
- fields_for(object_name, *(args << options), &proc)
- concat('</form>'.html_safe!)
- end
- alias_method :form_remote_for, :remote_form_for
-
- # Returns a button input tag with the element name of +name+ and a value (i.e., display text) of +value+
- # that will submit form using XMLHttpRequest in the background instead of a regular POST request that
- # reloads the page.
- #
- # # Create a button that submits to the create action
- # #
- # # Generates: <input name="create_btn" onclick="new Ajax.Request('/testing/create',
- # # {asynchronous:true, evalScripts:true, parameters:Form.serialize(this.form)});
- # # return false;" type="button" value="Create" />
- # <%= submit_to_remote 'create_btn', 'Create', :url => { :action => 'create' } %>
- #
- # # Submit to the remote action update and update the DIV succeed or fail based
- # # on the success or failure of the request
- # #
- # # Generates: <input name="update_btn" onclick="new Ajax.Updater({success:'succeed',failure:'fail'},
- # # '/testing/update', {asynchronous:true, evalScripts:true, parameters:Form.serialize(this.form)});
- # # return false;" type="button" value="Update" />
- # <%= submit_to_remote 'update_btn', 'Update', :url => { :action => 'update' },
- # :update => { :success => "succeed", :failure => "fail" }
- #
- # <tt>options</tt> argument is the same as in form_remote_tag.
- def submit_to_remote(name, value, options = {})
- options[:with] ||= 'Form.serialize(this.form)'
-
- html_options = options.delete(:html) || {}
- html_options[:name] = name
-
- button_to_remote(value, options, html_options)
- end
-
- # Returns '<tt>eval(request.responseText)</tt>' which is the JavaScript function
- # that +form_remote_tag+ can call in <tt>:complete</tt> to evaluate a multiple
- # update return document using +update_element_function+ calls.
- def evaluate_remote_response
- "eval(request.responseText)"
- end
-
# Returns the JavaScript needed for a remote function.
# Takes the same arguments as link_to_remote.
#
@@ -477,99 +126,6 @@ module ActionView
return function
end
- # Observes the field with the DOM ID specified by +field_id+ and calls a
- # callback when its contents have changed. The default callback is an
- # Ajax call. By default the value of the observed field is sent as a
- # parameter with the Ajax call.
- #
- # Example:
- # # Generates: new Form.Element.Observer('suggest', 0.25, function(element, value) {new Ajax.Updater('suggest',
- # # '/testing/find_suggestion', {asynchronous:true, evalScripts:true, parameters:'q=' + value})})
- # <%= observe_field :suggest, :url => { :action => :find_suggestion },
- # :frequency => 0.25,
- # :update => :suggest,
- # :with => 'q'
- # %>
- #
- # Required +options+ are either of:
- # <tt>:url</tt>:: +url_for+-style options for the action to call
- # when the field has changed.
- # <tt>:function</tt>:: Instead of making a remote call to a URL, you
- # can specify javascript code to be called instead.
- # Note that the value of this option is used as the
- # *body* of the javascript function, a function definition
- # with parameters named element and value will be generated for you
- # for example:
- # observe_field("glass", :frequency => 1, :function => "alert('Element changed')")
- # will generate:
- # new Form.Element.Observer('glass', 1, function(element, value) {alert('Element changed')})
- # The element parameter is the DOM element being observed, and the value is its value at the
- # time the observer is triggered.
- #
- # Additional options are:
- # <tt>:frequency</tt>:: The frequency (in seconds) at which changes to
- # this field will be detected. Not setting this
- # option at all or to a value equal to or less than
- # zero will use event based observation instead of
- # time based observation.
- # <tt>:update</tt>:: Specifies the DOM ID of the element whose
- # innerHTML should be updated with the
- # XMLHttpRequest response text.
- # <tt>:with</tt>:: A JavaScript expression specifying the parameters
- # for the XMLHttpRequest. The default is to send the
- # key and value of the observed field. Any custom
- # expressions should return a valid URL query string.
- # The value of the field is stored in the JavaScript
- # variable +value+.
- #
- # Examples
- #
- # :with => "'my_custom_key=' + value"
- # :with => "'person[name]=' + prompt('New name')"
- # :with => "Form.Element.serialize('other-field')"
- #
- # Finally
- # :with => 'name'
- # is shorthand for
- # :with => "'name=' + value"
- # This essentially just changes the key of the parameter.
- #
- # Additionally, you may specify any of the options documented in the
- # <em>Common options</em> section at the top of this document.
- #
- # Example:
- #
- # # Sends params: {:title => 'Title of the book'} when the book_title input
- # # field is changed.
- # observe_field 'book_title',
- # :url => 'http://example.com/books/edit/1',
- # :with => 'title'
- #
- #
- def observe_field(field_id, options = {})
- if options[:frequency] && options[:frequency] > 0
- build_observer('Form.Element.Observer', field_id, options)
- else
- build_observer('Form.Element.EventObserver', field_id, options)
- end
- end
-
- # Observes the form with the DOM ID specified by +form_id+ and calls a
- # callback when its contents have changed. The default callback is an
- # Ajax call. By default all fields of the observed field are sent as
- # parameters with the Ajax call.
- #
- # The +options+ for +observe_form+ are the same as the options for
- # +observe_field+. The JavaScript variable +value+ available to the
- # <tt>:with</tt> option is set to the serialized form by default.
- def observe_form(form_id, options = {})
- if options[:frequency]
- build_observer('Form.Observer', form_id, options)
- else
- build_observer('Form.EventObserver', form_id, options)
- end
- end
-
# All the methods were moved to GeneratorMethods so that
# #include_helpers_from_context has nothing to overwrite.
class JavaScriptGenerator #:nodoc:
diff --git a/actionpack/lib/action_view/helpers/translation_helper.rb b/actionpack/lib/action_view/helpers/translation_helper.rb
index 35c431d78d..ad18339c60 100644
--- a/actionpack/lib/action_view/helpers/translation_helper.rb
+++ b/actionpack/lib/action_view/helpers/translation_helper.rb
@@ -25,11 +25,15 @@ module ActionView
end
alias :l :localize
-
private
+
def scope_key_by_partial(key)
if key.to_s.first == "."
- template.path_without_format_and_extension.gsub(%r{/_?}, ".") + key.to_s
+ if @_virtual_path
+ @_virtual_path.gsub(%r{/_?}, ".") + key.to_s
+ else
+ raise "Cannot use t(#{key.inspect}) shortcut because path is not available"
+ end
else
key
end
diff --git a/actionpack/lib/action_view/helpers/url_helper.rb b/actionpack/lib/action_view/helpers/url_helper.rb
index 511386fede..4424dbba42 100644
--- a/actionpack/lib/action_view/helpers/url_helper.rb
+++ b/actionpack/lib/action_view/helpers/url_helper.rb
@@ -305,12 +305,11 @@ module ActionView
request_token_tag = tag(:input, :type => "hidden", :name => request_forgery_protection_token.to_s, :value => form_authenticity_token)
end
- if confirm = html_options.delete("confirm")
- html_options["onclick"] = "return #{confirm_javascript_function(confirm)};"
- end
url = options.is_a?(String) ? options : self.url_for(options)
name ||= url
+
+ convert_options_to_javascript!(html_options, url)
html_options.merge!("type" => "submit", "value" => name)
@@ -563,55 +562,6 @@ module ActionView
end
private
- def convert_options_to_javascript!(html_options, url = '')
- confirm, popup = html_options.delete("confirm"), html_options.delete("popup")
-
- method, href = html_options.delete("method"), html_options['href']
-
- html_options["onclick"] = case
- when popup && method
- raise ActionView::ActionViewError, "You can't use :popup and :method in the same link"
- when confirm && popup
- "if (#{confirm_javascript_function(confirm)}) { #{popup_javascript_function(popup)} };return false;"
- when confirm && method
- "if (#{confirm_javascript_function(confirm)}) { #{method_javascript_function(method, url, href)} };return false;"
- when confirm
- "return #{confirm_javascript_function(confirm)};"
- when method
- "#{method_javascript_function(method, url, href)}return false;"
- when popup
- "#{popup_javascript_function(popup)}return false;"
- else
- html_options["onclick"]
- end
- end
-
- def confirm_javascript_function(confirm)
- "confirm('#{escape_javascript(confirm)}')"
- end
-
- def popup_javascript_function(popup)
- popup.is_a?(Array) ? "window.open(this.href,'#{popup.first}','#{popup.last}');" : "window.open(this.href);"
- end
-
- def method_javascript_function(method, url = '', href = nil)
- action = (href && url.size > 0) ? "'#{url}'" : 'this.href'
- submit_function =
- "var f = document.createElement('form'); f.style.display = 'none'; " +
- "this.parentNode.appendChild(f); f.method = 'POST'; f.action = #{action};"
-
- unless method == :post
- submit_function << "var m = document.createElement('input'); m.setAttribute('type', 'hidden'); "
- submit_function << "m.setAttribute('name', '_method'); m.setAttribute('value', '#{method}'); f.appendChild(m);"
- end
-
- if protect_against_forgery?
- submit_function << "var s = document.createElement('input'); s.setAttribute('type', 'hidden'); "
- submit_function << "s.setAttribute('name', '#{request_forgery_protection_token}'); s.setAttribute('value', '#{escape_javascript form_authenticity_token}'); f.appendChild(s);"
- end
- submit_function << "f.submit();"
- end
-
# Processes the +html_options+ hash, converting the boolean
# attributes from true/false form into the form required by
# HTML/XHTML. (An attribute is considered to be boolean if
diff --git a/actionpack/lib/action_view/railtie.rb b/actionpack/lib/action_view/railtie.rb
index 968dc7b25e..d9e2557d89 100644
--- a/actionpack/lib/action_view/railtie.rb
+++ b/actionpack/lib/action_view/railtie.rb
@@ -3,7 +3,7 @@ require "rails"
module ActionView
class Railtie < Rails::Railtie
- plugin_name :action_view
+ railtie_name :action_view
require "action_view/railties/subscriber"
subscriber ActionView::Railties::Subscriber.new
diff --git a/actionpack/lib/action_view/template.rb b/actionpack/lib/action_view/template.rb
index adaf6544a7..cd6b1930a1 100644
--- a/actionpack/lib/action_view/template.rb
+++ b/actionpack/lib/action_view/template.rb
@@ -87,9 +87,9 @@ module ActionView
source = <<-end_src
def #{method_name}(local_assigns)
- old_output_buffer = output_buffer;#{locals_code};#{code}
+ _old_virtual_path, @_virtual_path = @_virtual_path, #{@details[:virtual_path].inspect};_old_output_buffer = output_buffer;#{locals_code};#{code}
ensure
- self.output_buffer = old_output_buffer
+ @_virtual_path, self.output_buffer = _old_virtual_path, _old_output_buffer
end
end_src
diff --git a/actionpack/lib/action_view/template/resolver.rb b/actionpack/lib/action_view/template/resolver.rb
index c6a17907ff..340a6afe5e 100644
--- a/actionpack/lib/action_view/template/resolver.rb
+++ b/actionpack/lib/action_view/template/resolver.rb
@@ -117,15 +117,18 @@ module ActionView
# # :api: plugin
def path_to_details(path)
# [:erb, :format => :html, :locale => :en, :partial => true/false]
- if m = path.match(%r'(?:^|/)(_)?[\w-]+((?:\.[\w-]+)*)\.(\w+)$')
- partial = m[1] == '_'
- details = (m[2]||"").split('.').reject { |e| e.empty? }
- handler = Template.handler_class_for_extension(m[3])
+ if m = path.match(%r'((^|.*/)(_)?[\w-]+)((?:\.[\w-]+)*)\.(\w+)$')
+ partial = m[3] == '_'
+ details = (m[4]||"").split('.').reject { |e| e.empty? }
+ handler = Template.handler_class_for_extension(m[5])
format = Mime[details.last] && details.pop.to_sym
locale = details.last && details.pop.to_sym
- return handler, :format => format, :locale => locale, :partial => partial
+ virtual_path = (m[1].gsub("#{@path}/", "") << details.join("."))
+
+ return handler, :format => format, :locale => locale, :partial => partial,
+ :virtual_path => virtual_path
end
end
end
diff --git a/actionpack/test/abstract/collector_test.rb b/actionpack/test/abstract/collector_test.rb
new file mode 100644
index 0000000000..2ebcebbbb7
--- /dev/null
+++ b/actionpack/test/abstract/collector_test.rb
@@ -0,0 +1,57 @@
+require 'abstract_unit'
+
+module AbstractController
+ module Testing
+ class MyCollector
+ include Collector
+ attr_accessor :responses
+
+ def initialize
+ @responses = []
+ end
+
+ def custom(mime, *args, &block)
+ @responses << [mime, args, block]
+ end
+ end
+
+ class TestCollector < ActiveSupport::TestCase
+ test "responds to default mime types" do
+ collector = MyCollector.new
+ assert_respond_to collector, :html
+ assert_respond_to collector, :text
+ end
+
+ test "does not respond to unknown mime types" do
+ collector = MyCollector.new
+ assert !collector.respond_to?(:unknown)
+ end
+
+ test "register mime types on method missing" do
+ AbstractController::Collector.send(:remove_method, :js)
+ collector = MyCollector.new
+ assert !collector.respond_to?(:js)
+ collector.js
+ assert_respond_to collector, :js
+ end
+
+ test "does not register unknown mime types" do
+ collector = MyCollector.new
+ assert_raise NameError do
+ collector.unknown
+ end
+ end
+
+ test "generated methods call custom with args received" do
+ collector = MyCollector.new
+ collector.html
+ collector.text(:foo)
+ collector.js(:bar) { :baz }
+ assert_equal [Mime::HTML, [], nil], collector.responses[0]
+ assert_equal [Mime::TEXT, [:foo], nil], collector.responses[1]
+ assert_equal [Mime::JS, [:bar]], collector.responses[2][0,2]
+ assert_equal :baz, collector.responses[2][2].call
+ end
+ end
+ end
+end \ No newline at end of file
diff --git a/actionpack/test/abstract/helper_test.rb b/actionpack/test/abstract/helper_test.rb
index ade29140ba..0cdf5c2298 100644
--- a/actionpack/test/abstract/helper_test.rb
+++ b/actionpack/test/abstract/helper_test.rb
@@ -1,6 +1,6 @@
require 'abstract_unit'
-ActionController::Base.helpers_dir = File.dirname(__FILE__) + '/../fixtures/helpers'
+ActionController::Base.helpers_path = [File.dirname(__FILE__) + '/../fixtures/helpers']
module AbstractController
module Testing
diff --git a/actionpack/test/abstract/layouts_test.rb b/actionpack/test/abstract/layouts_test.rb
index df73d948f0..bf02e5a864 100644
--- a/actionpack/test/abstract/layouts_test.rb
+++ b/actionpack/test/abstract/layouts_test.rb
@@ -1,5 +1,4 @@
require 'abstract_unit'
-require 'active_support/core_ext/class/removal'
module AbstractControllerTests
module Layouts
@@ -67,7 +66,15 @@ module AbstractControllerTests
class WithChildOfImplied < WithStringImpliedChild
end
-
+
+ class WithProc < Base
+ layout proc { |c| "omg" }
+
+ def index
+ render :_template => ActionView::Template::Text.new("Hello proc!")
+ end
+ end
+
class WithSymbol < Base
layout :hello
@@ -198,6 +205,12 @@ module AbstractControllerTests
controller.process(:index)
assert_equal "Hello nil!", controller.response_body
end
+
+ test "when layout is specified as a proc, call it and use the layout returned" do
+ controller = WithProc.new
+ controller.process(:index)
+ assert_equal "OMGHI2U Hello proc!", controller.response_body
+ end
test "when layout is specified as a symbol, call the requested method and use the layout returned" do
controller = WithSymbol.new
diff --git a/actionpack/test/controller/helper_test.rb b/actionpack/test/controller/helper_test.rb
index 9030e562bb..e53e62d1ff 100644
--- a/actionpack/test/controller/helper_test.rb
+++ b/actionpack/test/controller/helper_test.rb
@@ -1,7 +1,7 @@
require 'abstract_unit'
require 'active_support/core_ext/kernel/reporting'
-ActionController::Base.helpers_dir = File.dirname(__FILE__) + '/../fixtures/helpers'
+ActionController::Base.helpers_path = [File.dirname(__FILE__) + '/../fixtures/helpers']
module Fun
class GamesController < ActionController::Base
@@ -31,7 +31,7 @@ module LocalAbcHelper
def c() end
end
-class HelperTest < Test::Unit::TestCase
+class HelperTest < ActiveSupport::TestCase
class TestController < ActionController::Base
attr_accessor :delegate_attr
def delegate_method() end
@@ -106,7 +106,7 @@ class HelperTest < Test::Unit::TestCase
end
def test_all_helpers_with_alternate_helper_dir
- @controller_class.helpers_dir = File.dirname(__FILE__) + '/../fixtures/alternate_helpers'
+ @controller_class.helpers_path = [File.dirname(__FILE__) + '/../fixtures/alternate_helpers']
# Reload helpers
@controller_class._helpers = Module.new
@@ -135,6 +135,18 @@ class HelperTest < Test::Unit::TestCase
assert methods.include?('foobar')
end
+ # TODO Add this deprecation back before Rails 3.0 final release
+ # def test_deprecation
+ # assert_deprecated do
+ # ActionController::Base.helpers_dir = "some/foo/bar"
+ # end
+ # assert_deprecated do
+ # assert_equal ["some/foo/bar"], ActionController::Base.helpers_dir
+ # end
+ # ensure
+ # ActionController::Base.helpers_path = [File.dirname(__FILE__) + '/../fixtures/helpers']
+ # end
+
private
def expected_helper_methods
TestHelper.instance_methods.map {|m| m.to_s }
@@ -154,7 +166,7 @@ class HelperTest < Test::Unit::TestCase
end
-class IsolatedHelpersTest < Test::Unit::TestCase
+class IsolatedHelpersTest < ActiveSupport::TestCase
class A < ActionController::Base
def index
render :inline => '<%= shout %>'
diff --git a/actionpack/test/dispatch/middleware_stack_test.rb b/actionpack/test/dispatch/middleware_stack_test.rb
index f4e18308ae..7cf6365af3 100644
--- a/actionpack/test/dispatch/middleware_stack_test.rb
+++ b/actionpack/test/dispatch/middleware_stack_test.rb
@@ -87,4 +87,10 @@ class MiddlewareStackTest < ActiveSupport::TestCase
end
assert_equal [:foo], @stack.last.send(:build_args)
end
+
+ test "lazy compares so unloaded constants can be loaded" do
+ @stack.use "UnknownMiddleware"
+ @stack.use :"MiddlewareStackTest::BazMiddleware"
+ assert @stack.include?("::MiddlewareStackTest::BazMiddleware")
+ end
end
diff --git a/actionpack/test/dispatch/routing_test.rb b/actionpack/test/dispatch/routing_test.rb
index 6dccabdb3f..dfe824fd70 100644
--- a/actionpack/test/dispatch/routing_test.rb
+++ b/actionpack/test/dispatch/routing_test.rb
@@ -141,19 +141,18 @@ class TestRoutingMapper < ActionDispatch::IntegrationTest
resources :rooms
end
- scope '(:locale)', :locale => /en|pl/ do
- resources :descriptions
- end
+ match '/info' => 'projects#info', :as => 'info'
namespace :admin do
- scope '(/:locale)', :locale => /en|pl/ do
+ scope '(:locale)', :locale => /en|pl/ do
resources :descriptions
end
end
- match '/info' => 'projects#info', :as => 'info'
-
- root :to => 'projects#index'
+ scope '(:locale)', :locale => /en|pl/ do
+ resources :descriptions
+ root :to => 'projects#index'
+ end
end
end
@@ -660,6 +659,14 @@ class TestRoutingMapper < ActionDispatch::IntegrationTest
end
end
+ def test_optional_scoped_root
+ with_test_routes do
+ assert_equal '/en', root_path("en")
+ get '/en'
+ assert_equal 'projects#index', @response.body
+ end
+ end
+
def test_optional_scoped_path
with_test_routes do
assert_equal '/en/descriptions', descriptions_path("en")
diff --git a/actionpack/test/fixtures/helpers/fun/games_helper.rb b/actionpack/test/fixtures/helpers/fun/games_helper.rb
index bf60d9db0c..3b7adce086 100644
--- a/actionpack/test/fixtures/helpers/fun/games_helper.rb
+++ b/actionpack/test/fixtures/helpers/fun/games_helper.rb
@@ -1,3 +1,5 @@
-module Fun::GamesHelper
- def stratego() "Iz guuut!" end
+module Fun
+ module GamesHelper
+ def stratego() "Iz guuut!" end
+ end
end \ No newline at end of file
diff --git a/actionpack/test/fixtures/helpers/fun/pdf_helper.rb b/actionpack/test/fixtures/helpers/fun/pdf_helper.rb
index c4aea5a3f3..0171be8500 100644
--- a/actionpack/test/fixtures/helpers/fun/pdf_helper.rb
+++ b/actionpack/test/fixtures/helpers/fun/pdf_helper.rb
@@ -1,3 +1,5 @@
-module Fun::PdfHelper
- def foobar() 'baz' end
+module Fun
+ module PdfHelper
+ def foobar() 'baz' end
+ end
end
diff --git a/actionpack/test/fixtures/test/translation.erb b/actionpack/test/fixtures/test/translation.erb
new file mode 100644
index 0000000000..81a837d1ff
--- /dev/null
+++ b/actionpack/test/fixtures/test/translation.erb
@@ -0,0 +1 @@
+<%= t('.helper') %> \ No newline at end of file
diff --git a/actionpack/test/template/ajax_helper_test.rb b/actionpack/test/template/ajax_helper_test.rb
new file mode 100644
index 0000000000..c925dbb8f6
--- /dev/null
+++ b/actionpack/test/template/ajax_helper_test.rb
@@ -0,0 +1,452 @@
+require 'abstract_unit'
+require 'active_model'
+
+class Author
+ extend ActiveModel::Naming
+ include ActiveModel::Conversion
+
+ attr_reader :id
+ def save
+ @id = 1
+ end
+
+ def new_record?
+ @id.nil?
+ end
+
+ def name
+ @id.nil? ? 'new author' : "author ##{@id}"
+ end
+end
+
+class Article
+ extend ActiveModel::Naming
+ include ActiveModel::Conversion
+ attr_reader :id
+ attr_reader :author_id
+
+ def save
+ @id = 1
+ @author_id = 1
+ end
+
+ def new_record?
+ @id.nil?
+ end
+
+ def name
+ @id.nil? ? 'new article' : "article ##{@id}"
+ end
+end
+
+class AjaxHelperBaseTest < ActionView::TestCase
+ attr_accessor :formats, :output_buffer
+
+ def reset_formats(format)
+ @format = format
+ end
+
+ def setup
+ super
+ @template = self
+ @controller = Class.new do
+
+ def url_for(options)
+ return optons unless options.is_a?(Hash)
+
+ url = options.delete(:only_path) ? '/' : 'http://www.example.com'
+
+ if controller = options.delete(:controller)
+ url << '/' << controller.to_s
+ end
+ if action = options.delete(:action)
+ url << '/' << action.to_s
+ end
+
+ if id = options.delete(:id)
+ url << '/' << id.to_s
+ end
+
+ url << hash_to_param(options) if options.any?
+
+ url.gsub!(/\/\/+/,'/')
+
+ url
+ end
+
+ private
+ def hash_to_param(hash)
+ hash.map { |k,v| "#{k}=#{v}" }.join('&').insert(0,'?')
+ end
+ end.new
+ end
+
+ protected
+ def request_forgery_protection_token
+ nil
+ end
+
+ def protect_against_forgery?
+ false
+ end
+end
+
+class AjaxHelperTest < AjaxHelperBaseTest
+ def _evaluate_assigns_and_ivars() end
+
+ def setup
+ @record = @author = Author.new
+ @article = Article.new
+ super
+ end
+
+ test "link_to_remote" do
+ assert_dom_equal %(<a class=\"fine\" href=\"#\" data-remote=\"true\" data-url=\"/whatnot\">Remove Author</a>),
+ link_to_remote("Remove Author", { :url => { :action => "whatnot" }}, { :class => "fine" })
+ assert_dom_equal %(<a href=\"#\" data-remote=\"true\" data-url=\"/whatnot\" data-oncomplete=\"alert(request.responseText)\">Remove Author</a>),
+ link_to_remote("Remove Author", :complete => "alert(request.responseText)", :url => { :action => "whatnot" })
+ assert_dom_equal %(<a href=\"#\" data-remote=\"true\" data-url=\"/whatnot\" data-onsuccess=\"alert(request.responseText)\">Remove Author</a>),
+ link_to_remote("Remove Author", :success => "alert(request.responseText)", :url => { :action => "whatnot" })
+ assert_dom_equal %(<a href=\"#\" data-remote=\"true\" data-url=\"/whatnot\" data-onfailure=\"alert(request.responseText)\">Remove Author</a>),
+ link_to_remote("Remove Author", :failure => "alert(request.responseText)", :url => { :action => "whatnot" })
+ assert_dom_equal %(<a href=\"#\" data-remote=\"true\" data-url=\"/whatnot?a=10&amp;b=20\" data-onfailure=\"alert(request.responseText)\">Remove Author</a>),
+ link_to_remote("Remove Author", :failure => "alert(request.responseText)", :url => { :action => "whatnot", :a => '10', :b => '20' })
+ assert_dom_equal %(<a href=\"#\" data-remote=\"true\" data-url=\"/whatnot\" data-remote-type=\"synchronous\">Remove Author</a>),
+ link_to_remote("Remove Author", :url => { :action => "whatnot" }, :type => :synchronous)
+ assert_dom_equal %(<a href=\"#\" data-remote=\"true\" data-url=\"/whatnot\" data-update-position=\"bottom\">Remove Author</a>),
+ link_to_remote("Remove Author", :url => { :action => "whatnot" }, :position => :bottom)
+ end
+
+ test "link_to_remote with url and oncomplete" do
+ actual = link_to_remote "undo", :url => { :controller => "words", :action => "undo", :n => 5 }, :complete => "undoRequestCompleted(request)"
+ expected = '<a href="#" data-url="/words/undo?n=5" data-remote="true" data-oncomplete="undoRequestCompleted(request)">undo</a>'
+ assert_dom_equal expected, actual
+ end
+
+ test "link_to_remote with delete" do
+ actual = link_to_remote("Remove Author", { :url => { :action => "whatnot" }, :method => 'delete'}, { :class => "fine" })
+ expected = '<a class="fine" rel="nofollow" href="#" data-remote="true" data-method="delete" data-url="/whatnot">Remove Author</a>'
+ assert_dom_equal expected, actual
+ end
+
+ test "link_to_remote using both url and href" do
+ expected = '<a href="/destroy" data-url="/destroy" data-update-success="posts" data-remote="true">Delete this Post</a>'
+ assert_dom_equal expected, link_to_remote( "Delete this Post",
+ { :update => "posts",
+ :url => { :action => "destroy" } },
+ :href => url_for(:action => "destroy"))
+ end
+
+ test "link_to_remote with update-success and url" do
+ expected = '<a href="#" data-url="/destroy" data-update-success="posts" data-update-failure="error" data-remote="true">Delete this Post</a>'
+ assert_dom_equal expected, link_to_remote( "Delete this Post", :url => { :action => "destroy"},
+ :update => { :success => "posts", :failure => "error" })
+ end
+
+ test "link_to_remote with before/after callbacks" do
+ assert_dom_equal %(<a href=\"#\" data-remote=\"true\" data-url=\"/whatnot\" data-onbefore=\"before();\" data-onafter=\"after();\">Remote outauthor</a>),
+ link_to_remote("Remote outauthor", :url => { :action => "whatnot" }, :before => "before();", :after => "after();")
+ end
+
+ test "link_to_remote using :with expression" do
+ expected = %(<a href=\"#\" data-remote=\"true\" data-url=\"/whatnot\" data-with=\"id=123\">Remote outauthor</a>)
+ assert_dom_equal expected, link_to_remote("Remote outauthor", :url => { :action => "whatnot" }, :with => "id=123")
+ end
+
+ test "link_to_remote using :condition expression" do
+ expected = %(<a href=\"#\" data-remote=\"true\" data-url=\"/whatnot\" data-condition=\"$('foo').val() == true\">Remote outauthor</a>)
+ assert_dom_equal expected, link_to_remote("Remote outauthor", :url => { :action => "whatnot" }, :condition => '$(\'foo\').val() == true')
+ end
+
+ test "link_to_remote using explicit :href" do
+ expected = %(<a href=\"http://www.example.com/testhref\" data-remote=\"true\" data-url=\"/whatnot\" data-condition=\"$('foo').val() == true\">Remote outauthor</a>)
+ assert_dom_equal expected, link_to_remote("Remote outauthor", {:url => { :action => "whatnot" }, :condition => '$(\'foo\').val() == true'}, :href => 'http://www.example.com/testhref')
+ end
+
+ test "link_to_remote using :submit" do
+ expected = %(<a href=\"#\" data-remote=\"true\" data-url=\"/whatnot\" data-submit=\"myForm\">Remote outauthor</a>)
+ assert_dom_equal expected, link_to_remote("Remote outauthor", :url => { :action => "whatnot" }, :submit => 'myForm')
+ end
+
+ test "link_to_remote with method delete" do
+ assert_dom_equal %(<a class=\"fine\" href=\"#\" data-remote=\"true\" data-url=\"/whatnot\" data-method=\"delete\" rel=\"nofollow\">Remote outauthor</a>),
+ link_to_remote("Remote outauthor", { :url => { :action => "whatnot" }, :method => "delete"}, { :class => "fine" })
+ end
+
+ test "link_to_remote with method delete as symbol" do
+ assert_dom_equal %(<a class=\"fine\" href=\"#\" data-remote=\"true\" data-url=\"/whatnot\" data-method=\"delete\" rel=\"nofollow\">Remote outauthor</a>),
+ link_to_remote("Remote outauthor", { :url => { :action => "whatnot" }, :method => :delete}, { :class => "fine" })
+ end
+
+ test "link_to_remote html options" do
+ assert_dom_equal %(<a class=\"fine\" href=\"#\" data-remote=\"true\" data-url=\"/whatnot\">Remote outauthor</a>),
+ link_to_remote("Remote outauthor", { :url => { :action => "whatnot" }, :html => { :class => "fine" } })
+ end
+
+ test "link_to_remote url quote escaping" do
+ assert_dom_equal %(<a href="#" data-remote=\"true\" data-url=\"/whatnot\\\'s\">Remote</a>),
+ link_to_remote("Remote", { :url => { :action => "whatnot's" } })
+ end
+
+ test "link_to_remote with confirm" do
+ assert_dom_equal %(<a class=\"fine\" href=\"#\" data-remote=\"true\" data-url=\"/whatnot\" data-method=\"delete\" rel=\"nofollow\" data-confirm="Are you sure?">Remote confirm</a>),
+ link_to_remote("Remote confirm", { :url => { :action => "whatnot" }, :method => "delete", :confirm => "Are you sure?"}, { :class => "fine" })
+ end
+
+ test "button_to_remote" do
+ assert_dom_equal %(<input class=\"fine\" type=\"button\" value=\"Remote outpost\" data-remote=\"true\" data-url=\"/whatnot\" />),
+ button_to_remote("Remote outpost", { :url => { :action => "whatnot" }}, { :class => "fine" })
+ assert_dom_equal %(<input type=\"button\" value=\"Remote outpost\" data-remote=\"true\" data-url=\"/whatnot\" data-oncomplete=\"alert(request.reponseText)\" />),
+ button_to_remote("Remote outpost", :complete => "alert(request.reponseText)", :url => { :action => "whatnot" })
+ assert_dom_equal %(<input type=\"button\" value=\"Remote outpost\" data-remote=\"true\" data-url=\"/whatnot\" data-onsuccess=\"alert(request.reponseText)\" />),
+ button_to_remote("Remote outpost", :success => "alert(request.reponseText)", :url => { :action => "whatnot" })
+ assert_dom_equal %(<input type=\"button\" value=\"Remote outpost\" data-remote=\"true\" data-url=\"/whatnot\" data-onfailure=\"alert(request.reponseText)\" />),
+ button_to_remote("Remote outpost", :failure => "alert(request.reponseText)", :url => { :action => "whatnot" })
+ assert_dom_equal %(<input type=\"button\" value=\"Remote outpost\" data-remote=\"true\" data-url=\"/whatnot?a=10&amp;b=20\" data-onfailure=\"alert(request.reponseText)\" />),
+ button_to_remote("Remote outpost", :failure => "alert(request.reponseText)", :url => { :action => "whatnot", :a => '10', :b => '20' })
+ end
+
+ test "button_to_remote with confirm" do
+ assert_dom_equal %(<input class=\"fine\" type=\"button\" value=\"Remote outpost\" data-remote=\"true\" data-url=\"/whatnot\" data-confirm="Are you sure?" />),
+ button_to_remote("Remote outpost", { :url => { :action => "whatnot" }, :confirm => "Are you sure?"}, { :class => "fine" })
+ end
+
+ test "button_to_remote with :submit" do
+ assert_dom_equal %(<input class=\"fine\" type=\"button\" value=\"Remote outpost\" data-remote=\"true\" data-url=\"/whatnot\" data-submit="myForm" />),
+ button_to_remote("Remote outpost", { :url => { :action => "whatnot" }, :submit => "myForm"}, { :class => "fine" })
+ end
+
+ test "periodically_call_remote" do
+ expected = "<script data-url='/mehr_bier' data-update-success='schremser_bier' type='application/json' data-frequency='10' data-periodical='true'></script>"
+ actual = periodically_call_remote(:update => "schremser_bier", :url => { :action => "mehr_bier" })
+ assert_dom_equal expected, actual
+ end
+
+ test "periodically_call_remote_with_frequency" do
+ expected = "<script data-periodical='true' type='application/json' data-frequency='2'></script>"
+ actual = periodically_call_remote(:frequency => 2)
+ assert_dom_equal expected, actual
+ end
+
+ test "periodically_call_remote_with_function" do
+ expected = "<script data-periodical=\"true\" type=\"application/json\" data-onobserve=\"alert('test')\" data-frequency='2'></script>"
+ actual = periodically_call_remote(:frequency => 2, :function => "alert('test')")
+ assert_dom_equal expected, actual
+ end
+
+ test "periodically_call_remote_with_update" do
+ actual = periodically_call_remote(:url => { :action => 'get_averages' }, :update => 'avg')
+ expected = "<script data-periodical='true' data-url='/get_averages' type='application/json' data-update-success='avg' data-frequency='10'></script>"
+ assert_dom_equal expected, actual
+ end
+
+ test "periodically_call_remote with update success and failure" do
+ actual = periodically_call_remote(:url => { :action => 'invoice', :id => 1 },:update => { :success => "invoice", :failure => "error" })
+ expected = "<script data-periodical='true' data-url='/invoice/1' type='application/json' data-update-success='invoice' data-frequency='10' data-update-failure='error'></script>"
+ assert_dom_equal expected, actual
+ end
+
+ test "periodically_call_remote with frequency and update" do
+ actual = periodically_call_remote(:url => 'update', :frequency => '20', :update => 'news_block')
+ expected = "<script data-periodical='true' data-url='update' type='application/json' data-update-success='news_block' data-frequency='20'></script>"
+ assert_dom_equal expected, actual
+ end
+
+ test "form_remote_tag" do
+ assert_dom_equal %(<form action=\"/fast\" method=\"post\" data-remote=\"true\" data-update-success=\"glass_of_beer\">),
+ form_remote_tag(:update => "glass_of_beer", :url => { :action => :fast } )
+ assert_dom_equal %(<form action=\"/fast\" method=\"post\" data-remote=\"true\" data-update-success=\"glass_of_beer\">),
+ form_remote_tag(:update => { :success => "glass_of_beer" }, :url => { :action => :fast })
+ assert_dom_equal %(<form action=\"/fast\" method=\"post\" data-remote=\"true\" data-update-failure=\"glass_of_water\">),
+ form_remote_tag(:update => { :failure => "glass_of_water" }, :url => { :action => :fast })
+ assert_dom_equal %(<form action=\"/fast\" method=\"post\" data-remote=\"true\" data-update-success=\"glass_of_beer\" data-update-failure=\"glass_of_water\">),
+ form_remote_tag(:update => { :success => 'glass_of_beer', :failure => "glass_of_water" }, :url => { :action => :fast })
+ end
+
+ test "form_remote_tag with method" do
+ assert_dom_equal %(<form action=\"/fast\" method=\"post\" data-remote=\"true\" data-update-success=\"glass_of_beer\"><div style='margin:0;padding:0;display:inline'><input name='_method' type='hidden' value='put' /></div>),
+ form_remote_tag(:update => "glass_of_beer", :url => { :action => :fast }, :html => { :method => :put })
+ end
+
+ test "form_remote_tag with url" do
+ form_remote_tag(:url => '/posts' ){}
+ expected = "<form action='/posts' method='post' data-remote='true'></form>"
+ assert_dom_equal expected, output_buffer
+ end
+
+ test "form_remote_tag with block in erb" do
+ __in_erb_template = ''
+ form_remote_tag(:update => "glass_of_beer", :url => { :action => :fast }) { concat "Hello world!" }
+ assert_dom_equal %(<form action=\"/fast\" method=\"post\" data-remote=\"true\" data-update-success=\"glass_of_beer\">Hello world!</form>), output_buffer
+ end
+
+ test "remote_form_for with record identification with new record" do
+ remote_form_for(@record, {:html => { :id => 'create-author' }}) {}
+ expected = %(<form action='#{authors_path}' data-remote=\"true\" class='new_author' id='create-author' method='post'></form>)
+ assert_dom_equal expected, output_buffer
+ end
+
+ test "remote_form_for with url" do
+ remote_form_for(@record, {:html => { :id => 'create-author' }}) {}
+ expected = "<form action='/authors' data-remote='true' class='new_author' id='create-author' method='post'></form>"
+ assert_dom_equal expected, output_buffer
+ end
+
+ test "remote_form_for with record identification without html options" do
+ remote_form_for(@record) {}
+ expected = %(<form action='#{authors_path}' data-remote=\"true\" class='new_author' method='post' id='new_author'></form>)
+ assert_dom_equal expected, output_buffer
+ end
+
+ test "remote_form_for with record identification with existing record" do
+ @record.save
+ remote_form_for(@record) {}
+
+ expected = %(<form action='#{author_path(@record)}' id='edit_author_1' method='post' data-remote=\"true\" class='edit_author'><div style='margin:0;padding:0;display:inline'><input name='_method' type='hidden' value='put' /></div></form>)
+ assert_dom_equal expected, output_buffer
+ end
+
+ test "remote_form_for with new nested object and an excisting parent" do
+ @author.save
+ remote_form_for([@author, @article]) {}
+
+ expected = %(<form action='#{author_articles_path(@author)}' data-remote=\"true\" class='new_article' method='post' id='new_article'></form>)
+ assert_dom_equal expected, output_buffer
+ end
+
+ test "remote_form_for with existing object in list" do
+ @author.save
+ @article.save
+
+ remote_form_for([@author, @article]) {}
+
+ expected = %(<form action='#{author_article_path(@author, @article)}' id='edit_article_#{@article.id}' method='post' data-remote=\"true\" class='edit_article'><div style='margin:0;padding:0;display:inline'><input name='_method' type='hidden' value='put' /></div></form>)
+ assert_dom_equal expected, output_buffer
+ end
+
+ test "on callbacks" do
+ callbacks = [:uninitialized, :loading, :loaded, :interactive, :complete, :success, :failure]
+ callbacks.each do |callback|
+ assert_dom_equal %(<form action=\"/fast\" method=\"post\" data-remote=\"true\" data-update-success=\"glass_of_beer\" data-on#{callback}=\"monkeys();\">),
+ form_remote_tag(:update => "glass_of_beer", :url => { :action => :fast }, callback=>"monkeys();")
+ assert_dom_equal %(<form action=\"/fast\" method=\"post\" data-remote=\"true\" data-update-success=\"glass_of_beer\" data-on#{callback}=\"monkeys();\">),
+ form_remote_tag(:update => { :success => "glass_of_beer" }, :url => { :action => :fast }, callback=>"monkeys();")
+ assert_dom_equal %(<form action=\"/fast\" method=\"post\" data-remote=\"true\" data-update-failure=\"glass_of_beer\" data-on#{callback}=\"monkeys();\">),
+ form_remote_tag(:update => { :failure => "glass_of_beer" }, :url => { :action => :fast }, callback=>"monkeys();")
+ assert_dom_equal %(<form action=\"/fast\" method=\"post\" data-remote=\"true\" data-update-failure=\"glass_of_water\" data-update-success=\"glass_of_beer\" data-on#{callback}=\"monkeys();\">),
+ form_remote_tag(:update => { :success => "glass_of_beer", :failure => "glass_of_water" }, :url => { :action => :fast }, callback=>"monkeys();")
+ end
+
+ #HTTP status codes 200 up to 599 have callbacks
+ #these should work
+ 100.upto(599) do |callback|
+ assert_dom_equal %(<form action=\"/fast\" method=\"post\" data-remote=\"true\" data-update-success=\"glass_of_beer\" data-on#{callback}=\"monkeys();\">),
+ form_remote_tag(:update => "glass_of_beer", :url => { :action => :fast }, callback=>"monkeys();")
+ end
+
+ #test 200 and 404
+ assert_dom_equal %(<form action=\"/fast\" method=\"post\" data-remote=\"true\" data-update-success=\"glass_of_beer\" data-on200=\"monkeys();\" data-on404=\"bananas();\">),
+ form_remote_tag(:update => "glass_of_beer", :url => { :action => :fast }, 200=>"monkeys();", 404=>"bananas();")
+
+ #these shouldn't
+ 1.upto(99) do |callback|
+ assert_dom_equal %(<form action=\"/fast\" method=\"post\" data-remote=\"true\" data-update-success=\"glass_of_beer\" data-on#{callback}=\"monkeys();\">),
+ form_remote_tag(:update => "glass_of_beer", :url => { :action => :fast }, callback=>"monkeys();")
+ end
+ 600.upto(999) do |callback|
+ assert_dom_equal %(<form action=\"/fast\" method=\"post\" data-remote=\"true\" data-update-success=\"glass_of_beer\" data-on#{callback}=\"monkeys();\">),
+ form_remote_tag(:update => "glass_of_beer", :url => { :action => :fast }, callback=>"monkeys();")
+ end
+
+ #test ultimate combo
+ assert_dom_equal %(<form data-on404=\"bananas();\" method=\"post\" data-onsuccess=\"s()\" action=\"/fast\" data-oncomplete=\"c();\" data-update-success=\"glass_of_beer\" data-on200=\"monkeys();\" data-onloading=\"c1()\" data-remote=\"true\" data-onfailure=\"f();\">),
+ form_remote_tag(:update => "glass_of_beer", :url => { :action => :fast }, :loading => "c1()", :success => "s()", :failure => "f();", :complete => "c();", 200=>"monkeys();", 404=>"bananas();")
+
+ end
+
+ test "submit_to_remote" do
+ assert_dom_equal %(<input name=\"More beer!\" type=\"button\" value=\"1000000\" data-url=\"/empty_bottle\" data-remote-submit=\"true\" data-update-success=\"empty_bottle\" />),
+ submit_to_remote("More beer!", 1_000_000, :url => { :action => 'empty_bottle' }, :update => "empty_bottle")
+ end
+
+ test "submit_to_remote simple" do
+ expected = "<input name='create_btn' type='button' value='Create' data-remote-submit='true' data-url='/create' />"
+ actual = submit_to_remote 'create_btn', 'Create', :url => { :action => 'create' }
+ assert_dom_equal expected, actual
+ end
+
+ test "submit_to_remote with success and failure" do
+ expected = "<input name='update_btn' data-url='/update' data-remote-submit='true' data-update-failure='fail' data-update-success='succeed' value='Update' type='button' />"
+ actual = submit_to_remote 'update_btn', 'Update', :url => { :action => 'update' }, :update => { :success => "succeed", :failure => "fail" }
+ assert_dom_equal expected, actual
+ end
+
+ test "observe_field" do
+ assert_dom_equal %(<script type=\"text/javascript\" data-observe=\"true\" data-observed=\"glass\" data-frequency=\"300\" type=\"application/json\" data-url=\"/reorder_if_empty\"></script>),
+ observe_field("glass", :frequency => 5.minutes, :url => { :action => "reorder_if_empty" })
+ end
+
+ test "observe_field with url, frequency, update and with" do
+ actual = observe_field :suggest, :url => { :action => :find_suggestion }, :frequency => 0.25, :update => :suggest, :with => 'q'
+ expected = "<script type='text/javascript' data-observe='true' data-observed='suggest' data-frequency='0.25' type='application/json' data-url='/find_suggestion' data-update-success='suggest' data-with='q'></script>"
+ assert_dom_equal actual, expected
+ end
+
+ test "observe_field default frequency" do
+ actual = observe_field :suggest
+ expected = "<script type='text/javascript' data-observe='true' data-observed='suggest' data-frequency='10' type='application/json'></script>"
+ assert_dom_equal actual, expected
+ end
+
+ test "observe_field using with option" do
+ expected = %(<script type=\"text/javascript\" data-observe=\"true\" data-observed=\"glass\" data-frequency=\"300\" type=\"application/json\" data-url=\"/check_value\" data-with=\"id=123\"></script>)
+ assert_dom_equal expected, observe_field("glass", :frequency => 5.minutes, :url => { :action => "check_value" }, :with => 'id=123')
+ end
+
+ test "observe_field using condition option" do
+ expected = %(<script type=\"text/javascript\" data-observe=\"true\" data-observed=\"glass\" data-frequency=\"300\" type=\"application/json\" data-url=\"/check_value\" data-condition=\"$('foo').val() == true\"></script>)
+ assert_dom_equal expected, observe_field("glass", :frequency => 5.minutes, :url => { :action => "check_value" }, :condition => '$(\'foo\').val() == true')
+ end
+
+ test "observe_field using json in with option" do
+ expected = %(<script data-with=\"{'id':value}\" data-observed=\"glass\" data-url=\"/check_value\" data-observe=\"true\" type=\"application/json\" data-frequency=\"300\"></script>)
+ assert_dom_equal expected, observe_field("glass", :frequency => 5.minutes, :url => { :action => "check_value" }, :with => "{'id':value}")
+ end
+
+ test "observe_field using function for callback" do
+ assert_dom_equal %(<script data-observed=\"glass\" data-observe=\"true\" type=\"application/json\" data-onobserve=\"alert('Element changed')\" data-frequency=\"300\"></script>),
+ observe_field("glass", :frequency => 5.minutes, :function => "alert('Element changed')")
+ end
+
+ test "observe_form" do
+ assert_dom_equal %(<script data-observed=\"cart\" data-url=\"/cart_changed\" data-observe=\"true\" type=\"application/json\" data-frequency=\"2\"></script>),
+ observe_form("cart", :frequency => 2, :url => { :action => "cart_changed" })
+ end
+
+ test "observe_form using function for callback" do
+ assert_dom_equal %(<script data-observed=\"cart\" data-observe=\"true\" type=\"application/json\" data-onobserve=\"alert('Form changed')\" data-frequency=\"2\"></script>),
+ observe_form("cart", :frequency => 2, :function => "alert('Form changed')")
+ end
+
+ test "observe_field without frequency" do
+ assert_dom_equal %(<script data-observed=\"glass\" data-observe=\"true\" type=\"application/json\" data-frequency='10'></script>),
+ observe_field("glass")
+ end
+
+ protected
+ def author_path(record)
+ "/authors/#{record.id}"
+ end
+
+ def authors_path
+ "/authors"
+ end
+
+ def author_articles_path(author)
+ "/authors/#{author.id}/articles"
+ end
+
+ def author_article_path(author, article)
+ "/authors/#{author.id}/articles/#{article.id}"
+ end
+end
diff --git a/actionpack/test/template/ajax_test.rb b/actionpack/test/template/ajax_test.rb
deleted file mode 100644
index aeb7c09b09..0000000000
--- a/actionpack/test/template/ajax_test.rb
+++ /dev/null
@@ -1,114 +0,0 @@
-require "abstract_unit"
-
-class AjaxTestCase < ActiveSupport::TestCase
- include ActionView::Helpers::AjaxHelper
- include ActionView::Helpers::TagHelper
-
- def assert_html(html, matches)
- matches.each do |match|
- assert_match(Regexp.new(Regexp.escape(match)), html)
- end
- end
-
- def self.assert_callbacks_work(&blk)
- define_method(:assert_callbacks_work, &blk)
-
- [:complete, :failure, :success, :interactive, :loaded, :loading, 404].each do |callback|
- test "#{callback} callback" do
- markup = assert_callbacks_work(callback)
- assert_html markup, %W(data-#{callback}-code="undoRequestCompleted\(request\)")
- end
- end
- end
-end
-
-class LinkToRemoteTest < AjaxTestCase
- def url_for(hash)
- "/blog/destroy/4"
- end
-
- def link(options = {})
- link_to_remote("Delete this post", "/blog/destroy/3", options)
- end
-
- test "with no update" do
- assert_html link, %w(href="/blog/destroy/4" Delete\ this\ post data-remote="true")
- end
-
- test "basic" do
- assert_html link(:update => "#posts"),
- %w(data-update-success="#posts")
- end
-
- test "using a url hash" do
- link = link_to_remote("Delete this post", {:controller => :blog}, :update => "#posts")
- assert_html link, %w(href="/blog/destroy/4" data-update-success="#posts")
- end
-
- test "with :html options" do
- expected = %{<a href="/blog/destroy/4" data-custom="me" data-remote="true" data-update-success="#posts">Delete this post</a>}
- assert_equal expected, link(:update => "#posts", :html => {"data-custom" => "me"})
- end
-
- test "with a hash for :update" do
- link = link(:update => {:success => "#posts", :failure => "#error"})
- assert_match(/data-update-success="#posts"/, link)
- assert_match(/data-update-failure="#error"/, link)
- end
-
- test "with positional parameters" do
- link = link(:position => :top, :update => "#posts")
- assert_match(/data\-update\-position="top"/, link)
- end
-
- test "with an optional method" do
- link = link(:method => "delete")
- assert_match(/data-method="delete"/, link)
- end
-
- class LegacyLinkToRemoteTest < AjaxTestCase
- include ActionView::Helpers::AjaxHelper::Rails2Compatibility
-
- def link(options)
- link_to_remote("Delete this post", "/blog/destroy/3", options)
- end
-
- test "basic link_to_remote with :url =>" do
- expected = %{<a href="/blog/destroy/3" data-remote="true" data-update-success="#posts">Delete this post</a>}
- assert_equal expected,
- link_to_remote("Delete this post", :url => "/blog/destroy/3", :update => "#posts")
- end
-
- assert_callbacks_work do |callback|
- link(callback => "undoRequestCompleted(request)")
- end
- end
-end
-
-class ButtonToRemoteTest < AjaxTestCase
- def button(options, html = {})
- button_to_remote("Remote outpost", options, html)
- end
-
- def url_for(*)
- "/whatnot"
- end
-
- class StandardTest < ButtonToRemoteTest
- test "basic" do
- button = button({:url => {:action => "whatnot"}}, {:class => "fine"})
- [/input/, /class="fine"/, /type="button"/, /value="Remote outpost"/,
- /data-url="\/whatnot"/].each do |match|
- assert_match(match, button)
- end
- end
- end
-
- class LegacyButtonToRemoteTest < ButtonToRemoteTest
- include ActionView::Helpers::AjaxHelper::Rails2Compatibility
-
- assert_callbacks_work do |callback|
- button(callback => "undoRequestCompleted(request)")
- end
- end
-end
diff --git a/actionpack/test/template/form_helper_test.rb b/actionpack/test/template/form_helper_test.rb
index 0c5c5d17ee..147d3dc05d 100644
--- a/actionpack/test/template/form_helper_test.rb
+++ b/actionpack/test/template/form_helper_test.rb
@@ -1232,7 +1232,7 @@ class FormHelperTest < ActionView::TestCase
# Perhaps this test should be moved to prototype helper tests.
def test_remote_form_for_with_labelled_builder
- self.extend ActionView::Helpers::PrototypeHelper
+ self.extend ActionView::Helpers::AjaxHelper
remote_form_for(:post, @post, :builder => LabelledFormBuilder) do |f|
concat f.text_field(:title)
@@ -1241,7 +1241,7 @@ class FormHelperTest < ActionView::TestCase
end
expected =
- %(<form action="http://www.example.com" onsubmit="new Ajax.Request('http://www.example.com', {asynchronous:true, evalScripts:true, parameters:Form.serialize(this)}); return false;" method="post">) +
+ %(<form action="http://www.example.com" data-remote="true" method="post">) +
"<label for='title'>Title:</label> <input name='post[title]' size='30' type='text' id='post_title' value='Hello World' /><br/>" +
"<label for='body'>Body:</label> <textarea name='post[body]' id='post_body' rows='20' cols='40'>Back to the hill and over it again!</textarea><br/>" +
"<label for='secret'>Secret:</label> <input name='post[secret]' type='hidden' value='0' /><input name='post[secret]' checked='checked' type='checkbox' id='post_secret' value='1' /><br/>" +
@@ -1397,10 +1397,10 @@ class FormHelperTest < ActionView::TestCase
end
def test_remote_form_for_with_html_options_adds_options_to_form_tag
- self.extend ActionView::Helpers::PrototypeHelper
+ self.extend ActionView::Helpers::AjaxHelper
remote_form_for(:post, @post, :html => {:id => 'some_form', :class => 'some_class'}) do |f| end
- expected = "<form action=\"http://www.example.com\" class=\"some_class\" id=\"some_form\" method=\"post\" onsubmit=\"new Ajax.Request('http://www.example.com', {asynchronous:true, evalScripts:true, parameters:Form.serialize(this)}); return false;\"></form>"
+ expected = "<form action=\"http://www.example.com\" class=\"some_class\" id=\"some_form\" method=\"post\" data-remote=\"true\"></form>"
assert_dom_equal expected, output_buffer
end
diff --git a/actionpack/test/template/form_tag_helper_test.rb b/actionpack/test/template/form_tag_helper_test.rb
index 47462b1237..c8d929cee8 100644
--- a/actionpack/test/template/form_tag_helper_test.rb
+++ b/actionpack/test/template/form_tag_helper_test.rb
@@ -285,35 +285,35 @@ class FormTagHelperTest < ActionView::TestCase
def test_submit_tag
assert_dom_equal(
- %(<input name='commit' onclick="if (window.hiddenCommit) { window.hiddenCommit.setAttribute('value', this.value); }else { hiddenCommit = document.createElement('input');hiddenCommit.type = 'hidden';hiddenCommit.value = this.value;hiddenCommit.name = this.name;this.form.appendChild(hiddenCommit); }this.setAttribute('originalValue', this.value);this.disabled = true;this.value='Saving...';alert('hello!');result = (this.form.onsubmit ? (this.form.onsubmit() ? this.form.submit() : false) : this.form.submit());if (result == false) { this.value = this.getAttribute('originalValue');this.disabled = false; }return result;" type="submit" value="Save" />),
- submit_tag("Save", :disable_with => "Saving...", :onclick => "alert('hello!')")
+ %(<input name='commit' data-disable-with="Saving..." onclick="alert('hello!');" type="submit" value="Save" />),
+ submit_tag("Save", :disable_with => "Saving...", :onclick => "alert('hello!');")
)
end
def test_submit_tag_with_no_onclick_options
assert_dom_equal(
- %(<input name='commit' onclick="if (window.hiddenCommit) { window.hiddenCommit.setAttribute('value', this.value); }else { hiddenCommit = document.createElement('input');hiddenCommit.type = 'hidden';hiddenCommit.value = this.value;hiddenCommit.name = this.name;this.form.appendChild(hiddenCommit); }this.setAttribute('originalValue', this.value);this.disabled = true;this.value='Saving...';result = (this.form.onsubmit ? (this.form.onsubmit() ? this.form.submit() : false) : this.form.submit());if (result == false) { this.value = this.getAttribute('originalValue');this.disabled = false; }return result;" type="submit" value="Save" />),
+ %(<input name='commit' data-disable-with="Saving..." type="submit" value="Save" />),
submit_tag("Save", :disable_with => "Saving...")
)
end
def test_submit_tag_with_confirmation
assert_dom_equal(
- %(<input name='commit' type='submit' value='Save' onclick="if (!confirm('Are you sure?')) return false; return true;"/>),
+ %(<input name='commit' type='submit' value='Save' data-confirm="Are you sure?"/>),
submit_tag("Save", :confirm => "Are you sure?")
)
end
def test_submit_tag_with_confirmation_and_with_disable_with
assert_dom_equal(
- %(<input name="commit" onclick="if (!confirm('Are you sure?')) return false; if (window.hiddenCommit) { window.hiddenCommit.setAttribute('value', this.value); }else { hiddenCommit = document.createElement('input');hiddenCommit.type = 'hidden';hiddenCommit.value = this.value;hiddenCommit.name = this.name;this.form.appendChild(hiddenCommit); }this.setAttribute('originalValue', this.value);this.disabled = true;this.value='Saving...';result = (this.form.onsubmit ? (this.form.onsubmit() ? this.form.submit() : false) : this.form.submit());if (result == false) { this.value = this.getAttribute('originalValue');this.disabled = false; }return result;" type="submit" value="Save" />),
+ %(<input name="commit" data-confirm="Are you sure?" data-disable-with="Saving..." type="submit" value="Save" />),
submit_tag("Save", :disable_with => "Saving...", :confirm => "Are you sure?")
)
end
def test_image_submit_tag_with_confirmation
assert_dom_equal(
- %(<input type="image" src="/images/save.gif" onclick="return confirm('Are you sure?');"/>),
+ %(<input type="image" src="/images/save.gif" data-confirm="Are you sure?"/>),
image_submit_tag("save.gif", :confirm => "Are you sure?")
)
end
diff --git a/actionpack/test/template/prototype_helper_test.rb b/actionpack/test/template/prototype_helper_test.rb
index 9225153798..86f9c231c0 100644
--- a/actionpack/test/template/prototype_helper_test.rb
+++ b/actionpack/test/template/prototype_helper_test.rb
@@ -82,199 +82,6 @@ class PrototypeHelperTest < PrototypeHelperBaseTest
super
end
- def test_link_to_remote
- assert_dom_equal %(<a class=\"fine\" href=\"#\" onclick=\"new Ajax.Request('http://www.example.com/whatnot', {asynchronous:true, evalScripts:true}); return false;\">Remote outauthor</a>),
- link_to_remote("Remote outauthor", { :url => { :action => "whatnot" }}, { :class => "fine" })
- assert_dom_equal %(<a href=\"#\" onclick=\"new Ajax.Request('http://www.example.com/whatnot', {asynchronous:true, evalScripts:true, onComplete:function(request){alert(request.responseText)}}); return false;\">Remote outauthor</a>),
- link_to_remote("Remote outauthor", :complete => "alert(request.responseText)", :url => { :action => "whatnot" })
- assert_dom_equal %(<a href=\"#\" onclick=\"new Ajax.Request('http://www.example.com/whatnot', {asynchronous:true, evalScripts:true, onSuccess:function(request){alert(request.responseText)}}); return false;\">Remote outauthor</a>),
- link_to_remote("Remote outauthor", :success => "alert(request.responseText)", :url => { :action => "whatnot" })
- assert_dom_equal %(<a href=\"#\" onclick=\"new Ajax.Request('http://www.example.com/whatnot', {asynchronous:true, evalScripts:true, onFailure:function(request){alert(request.responseText)}}); return false;\">Remote outauthor</a>),
- link_to_remote("Remote outauthor", :failure => "alert(request.responseText)", :url => { :action => "whatnot" })
- assert_dom_equal %(<a href=\"#\" onclick=\"new Ajax.Request('http://www.example.com/whatnot?a=10&amp;b=20', {asynchronous:true, evalScripts:true, onFailure:function(request){alert(request.responseText)}}); return false;\">Remote outauthor</a>),
- link_to_remote("Remote outauthor", :failure => "alert(request.responseText)", :url => { :action => "whatnot", :a => '10', :b => '20' })
- assert_dom_equal %(<a href=\"#\" onclick=\"new Ajax.Request('http://www.example.com/whatnot', {asynchronous:false, evalScripts:true}); return false;\">Remote outauthor</a>),
- link_to_remote("Remote outauthor", :url => { :action => "whatnot" }, :type => :synchronous)
- assert_dom_equal %(<a href=\"#\" onclick=\"new Ajax.Request('http://www.example.com/whatnot', {asynchronous:true, evalScripts:true, insertion:'bottom'}); return false;\">Remote outauthor</a>),
- link_to_remote("Remote outauthor", :url => { :action => "whatnot" }, :position => :bottom)
- end
-
- def test_link_to_remote_html_options
- assert_dom_equal %(<a class=\"fine\" href=\"#\" onclick=\"new Ajax.Request('http://www.example.com/whatnot', {asynchronous:true, evalScripts:true}); return false;\">Remote outauthor</a>),
- link_to_remote("Remote outauthor", { :url => { :action => "whatnot" }, :html => { :class => "fine" } })
- end
-
- def test_link_to_remote_url_quote_escaping
- assert_dom_equal %(<a href="#" onclick="new Ajax.Request('http://www.example.com/whatnot\\\'s', {asynchronous:true, evalScripts:true}); return false;">Remote</a>),
- link_to_remote("Remote", { :url => { :action => "whatnot's" } })
- end
-
- def test_button_to_remote
- assert_dom_equal %(<input class=\"fine\" type=\"button\" value=\"Remote outpost\" onclick=\"new Ajax.Request('http://www.example.com/whatnot', {asynchronous:true, evalScripts:true});\" />),
- button_to_remote("Remote outpost", { :url => { :action => "whatnot" }}, { :class => "fine" })
- assert_dom_equal %(<input type=\"button\" value=\"Remote outpost\" onclick=\"new Ajax.Request('http://www.example.com/whatnot', {asynchronous:true, evalScripts:true, onComplete:function(request){alert(request.reponseText)}});\" />),
- button_to_remote("Remote outpost", :complete => "alert(request.reponseText)", :url => { :action => "whatnot" })
- assert_dom_equal %(<input type=\"button\" value=\"Remote outpost\" onclick=\"new Ajax.Request('http://www.example.com/whatnot', {asynchronous:true, evalScripts:true, onSuccess:function(request){alert(request.reponseText)}});\" />),
- button_to_remote("Remote outpost", :success => "alert(request.reponseText)", :url => { :action => "whatnot" })
- assert_dom_equal %(<input type=\"button\" value=\"Remote outpost\" onclick=\"new Ajax.Request('http://www.example.com/whatnot', {asynchronous:true, evalScripts:true, onFailure:function(request){alert(request.reponseText)}});\" />),
- button_to_remote("Remote outpost", :failure => "alert(request.reponseText)", :url => { :action => "whatnot" })
- assert_dom_equal %(<input type=\"button\" value=\"Remote outpost\" onclick=\"new Ajax.Request('http://www.example.com/whatnot?a=10&amp;b=20', {asynchronous:true, evalScripts:true, onFailure:function(request){alert(request.reponseText)}});\" />),
- button_to_remote("Remote outpost", :failure => "alert(request.reponseText)", :url => { :action => "whatnot", :a => '10', :b => '20' })
- end
-
- def test_periodically_call_remote
- assert_dom_equal %(<script type="text/javascript">\n//<![CDATA[\nnew PeriodicalExecuter(function() {new Ajax.Updater('schremser_bier', 'http://www.example.com/mehr_bier', {asynchronous:true, evalScripts:true})}, 10)\n//]]>\n</script>),
- periodically_call_remote(:update => "schremser_bier", :url => { :action => "mehr_bier" })
- end
-
- def test_periodically_call_remote_with_frequency
- assert_dom_equal(
- "<script type=\"text/javascript\">\n//<![CDATA[\nnew PeriodicalExecuter(function() {new Ajax.Request('http://www.example.com/', {asynchronous:true, evalScripts:true})}, 2)\n//]]>\n</script>",
- periodically_call_remote(:frequency => 2)
- )
- end
-
- def test_form_remote_tag
- assert_dom_equal %(<form action=\"http://www.example.com/fast\" method=\"post\" onsubmit=\"new Ajax.Updater('glass_of_beer', 'http://www.example.com/fast', {asynchronous:true, evalScripts:true, parameters:Form.serialize(this)}); return false;\">),
- form_remote_tag(:update => "glass_of_beer", :url => { :action => :fast })
- assert_dom_equal %(<form action=\"http://www.example.com/fast\" method=\"post\" onsubmit=\"new Ajax.Updater({success:'glass_of_beer'}, 'http://www.example.com/fast', {asynchronous:true, evalScripts:true, parameters:Form.serialize(this)}); return false;\">),
- form_remote_tag(:update => { :success => "glass_of_beer" }, :url => { :action => :fast })
- assert_dom_equal %(<form action=\"http://www.example.com/fast\" method=\"post\" onsubmit=\"new Ajax.Updater({failure:'glass_of_water'}, 'http://www.example.com/fast', {asynchronous:true, evalScripts:true, parameters:Form.serialize(this)}); return false;\">),
- form_remote_tag(:update => { :failure => "glass_of_water" }, :url => { :action => :fast })
- assert_dom_equal %(<form action=\"http://www.example.com/fast\" method=\"post\" onsubmit=\"new Ajax.Updater({success:'glass_of_beer',failure:'glass_of_water'}, 'http://www.example.com/fast', {asynchronous:true, evalScripts:true, parameters:Form.serialize(this)}); return false;\">),
- form_remote_tag(:update => { :success => 'glass_of_beer', :failure => "glass_of_water" }, :url => { :action => :fast })
- end
-
- def test_form_remote_tag_with_method
- assert_dom_equal %(<form action=\"http://www.example.com/fast\" method=\"post\" onsubmit=\"new Ajax.Updater('glass_of_beer', 'http://www.example.com/fast', {asynchronous:true, evalScripts:true, parameters:Form.serialize(this)}); return false;\"><div style='margin:0;padding:0;display:inline'><input name='_method' type='hidden' value='put' /></div>),
- form_remote_tag(:update => "glass_of_beer", :url => { :action => :fast }, :html => { :method => :put })
- end
-
- def test_form_remote_tag_with_block_in_erb
- __in_erb_template = ''
- form_remote_tag(:update => "glass_of_beer", :url => { :action => :fast }) { concat "Hello world!" }
- assert_dom_equal %(<form action=\"http://www.example.com/fast\" method=\"post\" onsubmit=\"new Ajax.Updater('glass_of_beer', 'http://www.example.com/fast', {asynchronous:true, evalScripts:true, parameters:Form.serialize(this)}); return false;\">Hello world!</form>), output_buffer
- end
-
- def test_remote_form_for_with_record_identification_with_new_record
- remote_form_for(@record, {:html => { :id => 'create-author' }}) {}
-
- expected = %(<form action='#{authors_path}' onsubmit="new Ajax.Request('#{authors_path}', {asynchronous:true, evalScripts:true, parameters:Form.serialize(this)}); return false;" class='new_author' id='create-author' method='post'></form>)
- assert_dom_equal expected, output_buffer
- end
-
- def test_remote_form_for_with_record_identification_without_html_options
- remote_form_for(@record) {}
-
- expected = %(<form action='#{authors_path}' onsubmit="new Ajax.Request('#{authors_path}', {asynchronous:true, evalScripts:true, parameters:Form.serialize(this)}); return false;" class='new_author' method='post' id='new_author'></form>)
- assert_dom_equal expected, output_buffer
- end
-
- def test_remote_form_for_with_record_identification_with_existing_record
- @record.save
- remote_form_for(@record) {}
-
- expected = %(<form action='#{author_path(@record)}' id='edit_author_1' method='post' onsubmit="new Ajax.Request('#{author_path(@record)}', {asynchronous:true, evalScripts:true, parameters:Form.serialize(this)}); return false;" class='edit_author'><div style='margin:0;padding:0;display:inline'><input name='_method' type='hidden' value='put' /></div></form>)
- assert_dom_equal expected, output_buffer
- end
-
- def test_remote_form_for_with_new_object_in_list
- remote_form_for([@author, @article]) {}
-
- expected = %(<form action='#{author_articles_path(@author)}' onsubmit="new Ajax.Request('#{author_articles_path(@author)}', {asynchronous:true, evalScripts:true, parameters:Form.serialize(this)}); return false;" class='new_article' method='post' id='new_article'></form>)
- assert_dom_equal expected, output_buffer
- end
-
- def test_remote_form_for_with_existing_object_in_list
- @author.save
- @article.save
- remote_form_for([@author, @article]) {}
-
- expected = %(<form action='#{author_article_path(@author, @article)}' id='edit_article_1' method='post' onsubmit="new Ajax.Request('#{author_article_path(@author, @article)}', {asynchronous:true, evalScripts:true, parameters:Form.serialize(this)}); return false;" class='edit_article'><div style='margin:0;padding:0;display:inline'><input name='_method' type='hidden' value='put' /></div></form>)
- assert_dom_equal expected, output_buffer
- end
-
- def test_on_callbacks
- callbacks = [:uninitialized, :loading, :loaded, :interactive, :complete, :success, :failure]
- callbacks.each do |callback|
- assert_dom_equal %(<form action=\"http://www.example.com/fast\" method=\"post\" onsubmit=\"new Ajax.Updater('glass_of_beer', 'http://www.example.com/fast', {asynchronous:true, evalScripts:true, on#{callback.to_s.capitalize}:function(request){monkeys();}, parameters:Form.serialize(this)}); return false;">),
- form_remote_tag(:update => "glass_of_beer", :url => { :action => :fast }, callback=>"monkeys();")
- assert_dom_equal %(<form action=\"http://www.example.com/fast\" method=\"post\" onsubmit=\"new Ajax.Updater({success:'glass_of_beer'}, 'http://www.example.com/fast', {asynchronous:true, evalScripts:true, on#{callback.to_s.capitalize}:function(request){monkeys();}, parameters:Form.serialize(this)}); return false;">),
- form_remote_tag(:update => { :success => "glass_of_beer" }, :url => { :action => :fast }, callback=>"monkeys();")
- assert_dom_equal %(<form action=\"http://www.example.com/fast\" method=\"post\" onsubmit=\"new Ajax.Updater({failure:'glass_of_beer'}, 'http://www.example.com/fast', {asynchronous:true, evalScripts:true, on#{callback.to_s.capitalize}:function(request){monkeys();}, parameters:Form.serialize(this)}); return false;">),
- form_remote_tag(:update => { :failure => "glass_of_beer" }, :url => { :action => :fast }, callback=>"monkeys();")
- assert_dom_equal %(<form action=\"http://www.example.com/fast\" method=\"post\" onsubmit=\"new Ajax.Updater({success:'glass_of_beer',failure:'glass_of_water'}, 'http://www.example.com/fast', {asynchronous:true, evalScripts:true, on#{callback.to_s.capitalize}:function(request){monkeys();}, parameters:Form.serialize(this)}); return false;">),
- form_remote_tag(:update => { :success => "glass_of_beer", :failure => "glass_of_water" }, :url => { :action => :fast }, callback=>"monkeys();")
- end
-
- #HTTP status codes 200 up to 599 have callbacks
- #these should work
- 100.upto(599) do |callback|
- assert_dom_equal %(<form action=\"http://www.example.com/fast\" method=\"post\" onsubmit=\"new Ajax.Updater('glass_of_beer', 'http://www.example.com/fast', {asynchronous:true, evalScripts:true, on#{callback.to_s.capitalize}:function(request){monkeys();}, parameters:Form.serialize(this)}); return false;">),
- form_remote_tag(:update => "glass_of_beer", :url => { :action => :fast }, callback=>"monkeys();")
- end
-
- #test 200 and 404
- assert_dom_equal %(<form action=\"http://www.example.com/fast\" method=\"post\" onsubmit=\"new Ajax.Updater('glass_of_beer', 'http://www.example.com/fast', {asynchronous:true, evalScripts:true, on200:function(request){monkeys();}, on404:function(request){bananas();}, parameters:Form.serialize(this)}); return false;">),
- form_remote_tag(:update => "glass_of_beer", :url => { :action => :fast }, 200=>"monkeys();", 404=>"bananas();")
-
- #these shouldn't
- 1.upto(99) do |callback|
- assert_dom_equal %(<form action=\"http://www.example.com/fast\" method=\"post\" onsubmit=\"new Ajax.Updater('glass_of_beer', 'http://www.example.com/fast', {asynchronous:true, evalScripts:true, parameters:Form.serialize(this)}); return false;">),
- form_remote_tag(:update => "glass_of_beer", :url => { :action => :fast }, callback=>"monkeys();")
- end
- 600.upto(999) do |callback|
- assert_dom_equal %(<form action=\"http://www.example.com/fast\" method=\"post\" onsubmit=\"new Ajax.Updater('glass_of_beer', 'http://www.example.com/fast', {asynchronous:true, evalScripts:true, parameters:Form.serialize(this)}); return false;">),
- form_remote_tag(:update => "glass_of_beer", :url => { :action => :fast }, callback=>"monkeys();")
- end
-
- #test ultimate combo
- assert_dom_equal %(<form action=\"http://www.example.com/fast\" method=\"post\" onsubmit=\"new Ajax.Updater('glass_of_beer', 'http://www.example.com/fast', {asynchronous:true, evalScripts:true, on200:function(request){monkeys();}, on404:function(request){bananas();}, onComplete:function(request){c();}, onFailure:function(request){f();}, onLoading:function(request){c1()}, onSuccess:function(request){s()}, parameters:Form.serialize(this)}); return false;\">),
- form_remote_tag(:update => "glass_of_beer", :url => { :action => :fast }, :loading => "c1()", :success => "s()", :failure => "f();", :complete => "c();", 200=>"monkeys();", 404=>"bananas();")
-
- end
-
- def test_submit_to_remote
- assert_dom_equal %(<input name=\"More beer!\" onclick=\"new Ajax.Updater('empty_bottle', 'http://www.example.com/', {asynchronous:true, evalScripts:true, parameters:Form.serialize(this.form)});\" type=\"button\" value=\"1000000\" />),
- submit_to_remote("More beer!", 1_000_000, :update => "empty_bottle")
- end
-
- def test_observe_field
- assert_dom_equal %(<script type=\"text/javascript\">\n//<![CDATA[\nnew Form.Element.Observer('glass', 300, function(element, value) {new Ajax.Request('http://www.example.com/reorder_if_empty', {asynchronous:true, evalScripts:true, parameters:value})})\n//]]>\n</script>),
- observe_field("glass", :frequency => 5.minutes, :url => { :action => "reorder_if_empty" })
- end
-
- def test_observe_field_using_with_option
- expected = %(<script type=\"text/javascript\">\n//<![CDATA[\nnew Form.Element.Observer('glass', 300, function(element, value) {new Ajax.Request('http://www.example.com/check_value', {asynchronous:true, evalScripts:true, parameters:'id=' + encodeURIComponent(value)})})\n//]]>\n</script>)
- assert_dom_equal expected, observe_field("glass", :frequency => 5.minutes, :url => { :action => "check_value" }, :with => 'id')
- assert_dom_equal expected, observe_field("glass", :frequency => 5.minutes, :url => { :action => "check_value" }, :with => "'id=' + encodeURIComponent(value)")
- end
-
- def test_observe_field_using_json_in_with_option
- expected = %(<script type=\"text/javascript\">\n//<![CDATA[\nnew Form.Element.Observer('glass', 300, function(element, value) {new Ajax.Request('http://www.example.com/check_value', {asynchronous:true, evalScripts:true, parameters:{'id':value}})})\n//]]>\n</script>)
- assert_dom_equal expected, observe_field("glass", :frequency => 5.minutes, :url => { :action => "check_value" }, :with => "{'id':value}")
- end
-
- def test_observe_field_using_function_for_callback
- assert_dom_equal %(<script type=\"text/javascript\">\n//<![CDATA[\nnew Form.Element.Observer('glass', 300, function(element, value) {alert('Element changed')})\n//]]>\n</script>),
- observe_field("glass", :frequency => 5.minutes, :function => "alert('Element changed')")
- end
-
- def test_observe_form
- assert_dom_equal %(<script type=\"text/javascript\">\n//<![CDATA[\nnew Form.Observer('cart', 2, function(element, value) {new Ajax.Request('http://www.example.com/cart_changed', {asynchronous:true, evalScripts:true, parameters:value})})\n//]]>\n</script>),
- observe_form("cart", :frequency => 2, :url => { :action => "cart_changed" })
- end
-
- def test_observe_form_using_function_for_callback
- assert_dom_equal %(<script type=\"text/javascript\">\n//<![CDATA[\nnew Form.Observer('cart', 2, function(element, value) {alert('Form changed')})\n//]]>\n</script>),
- observe_form("cart", :frequency => 2, :function => "alert('Form changed')")
- end
-
- def test_observe_field_without_frequency
- assert_dom_equal %(<script type=\"text/javascript\">\n//<![CDATA[\nnew Form.Element.EventObserver('glass', function(element, value) {new Ajax.Request('http://www.example.com/', {asynchronous:true, evalScripts:true, parameters:value})})\n//]]>\n</script>),
- observe_field("glass")
- end
-
def test_update_page
old_output_buffer = output_buffer
diff --git a/actionpack/test/template/translation_helper_test.rb b/actionpack/test/template/translation_helper_test.rb
index d67d2c7911..4b73c44f7e 100644
--- a/actionpack/test/template/translation_helper_test.rb
+++ b/actionpack/test/template/translation_helper_test.rb
@@ -1,9 +1,9 @@
require 'abstract_unit'
-class TranslationHelperTest < Test::Unit::TestCase
+class TranslationHelperTest < ActiveSupport::TestCase
include ActionView::Helpers::TagHelper
include ActionView::Helpers::TranslationHelper
-
+
attr_reader :request
def setup
end
@@ -25,8 +25,8 @@ class TranslationHelperTest < Test::Unit::TestCase
end
def test_scoping_by_partial
- expects(:template).returns(stub(:path_without_format_and_extension => "people/index"))
- I18n.expects(:translate).with("people.index.foo", :locale => 'en', :raise => true).returns("")
- translate ".foo", :locale => 'en'
+ I18n.expects(:translate).with("test.translation.helper", :raise => true).returns("helper")
+ @view = ActionView::Base.new(ActionController::Base.view_paths, {})
+ assert_equal "helper", @view.render(:file => "test/translation")
end
end
diff --git a/actionpack/test/template/url_helper_test.rb b/actionpack/test/template/url_helper_test.rb
index d4b58efe1e..c0e6826ec5 100644
--- a/actionpack/test/template/url_helper_test.rb
+++ b/actionpack/test/template/url_helper_test.rb
@@ -76,7 +76,7 @@ class UrlHelperTest < ActionView::TestCase
def test_button_to_with_javascript_confirm
assert_dom_equal(
- "<form method=\"post\" action=\"http://www.example.com\" class=\"button-to\"><div><input onclick=\"return confirm('Are you sure?');\" type=\"submit\" value=\"Hello\" /></div></form>",
+ "<form method=\"post\" action=\"http://www.example.com\" class=\"button-to\"><div><input data-confirm=\"Are you sure?\" type=\"submit\" value=\"Hello\" /></div></form>",
button_to("Hello", "http://www.example.com", :confirm => "Are you sure?")
)
end
@@ -170,76 +170,76 @@ class UrlHelperTest < ActionView::TestCase
def test_link_tag_with_javascript_confirm
assert_dom_equal(
- "<a href=\"http://www.example.com\" onclick=\"return confirm('Are you sure?');\">Hello</a>",
+ "<a href=\"http://www.example.com\" data-confirm=\"Are you sure?\">Hello</a>",
link_to("Hello", "http://www.example.com", :confirm => "Are you sure?")
)
assert_dom_equal(
- "<a href=\"http://www.example.com\" onclick=\"return confirm('You can\\'t possibly be sure, can you?');\">Hello</a>",
+ "<a href=\"http://www.example.com\" data-confirm=\"You can\'t possibly be sure, can you?\">Hello</a>",
link_to("Hello", "http://www.example.com", :confirm => "You can't possibly be sure, can you?")
)
assert_dom_equal(
- "<a href=\"http://www.example.com\" onclick=\"return confirm('You can\\'t possibly be sure,\\n can you?');\">Hello</a>",
+ "<a href=\"http://www.example.com\" data-confirm=\"You can\'t possibly be sure,\n can you?\">Hello</a>",
link_to("Hello", "http://www.example.com", :confirm => "You can't possibly be sure,\n can you?")
)
end
def test_link_tag_with_popup
assert_dom_equal(
- "<a href=\"http://www.example.com\" onclick=\"window.open(this.href);return false;\">Hello</a>",
+ "<a href=\"http://www.example.com\" data-popup=\"true\">Hello</a>",
link_to("Hello", "http://www.example.com", :popup => true)
)
assert_dom_equal(
- "<a href=\"http://www.example.com\" onclick=\"window.open(this.href);return false;\">Hello</a>",
+ "<a href=\"http://www.example.com\" data-popup=\"true\">Hello</a>",
link_to("Hello", "http://www.example.com", :popup => 'true')
)
assert_dom_equal(
- "<a href=\"http://www.example.com\" onclick=\"window.open(this.href,'window_name','width=300,height=300');return false;\">Hello</a>",
+ "<a href=\"http://www.example.com\" data-popup=\"{title: 'window_name', options: 'width=300,height=300'}\">Hello</a>",
link_to("Hello", "http://www.example.com", :popup => ['window_name', 'width=300,height=300'])
)
end
def test_link_tag_with_popup_and_javascript_confirm
assert_dom_equal(
- "<a href=\"http://www.example.com\" onclick=\"if (confirm('Fo\\' sho\\'?')) { window.open(this.href); };return false;\">Hello</a>",
+ "<a href=\"http://www.example.com\" data-confirm=\"Fo\' sho\'?\" data-popup=\"true\">Hello</a>",
link_to("Hello", "http://www.example.com", { :popup => true, :confirm => "Fo' sho'?" })
)
assert_dom_equal(
- "<a href=\"http://www.example.com\" onclick=\"if (confirm('Are you serious?')) { window.open(this.href,'window_name','width=300,height=300'); };return false;\">Hello</a>",
+ "<a href=\"http://www.example.com\" data-confirm=\"Are you serious?\" data-popup=\"{title: 'window_name', options: 'width=300,height=300'}\">Hello</a>",
link_to("Hello", "http://www.example.com", { :popup => ['window_name', 'width=300,height=300'], :confirm => "Are you serious?" })
)
end
def test_link_tag_using_post_javascript
assert_dom_equal(
- "<a href='http://www.example.com' onclick=\"var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;f.submit();return false;\">Hello</a>",
+ "<a href='http://www.example.com' data-url='http://www.example.com' data-method=\"post\">Hello</a>",
link_to("Hello", "http://www.example.com", :method => :post)
)
end
def test_link_tag_using_delete_javascript
assert_dom_equal(
- "<a href='http://www.example.com' onclick=\"var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);f.submit();return false;\">Destroy</a>",
+ "<a href='http://www.example.com' data-url='http://www.example.com' rel=\"nofollow\" data-method=\"delete\">Destroy</a>",
link_to("Destroy", "http://www.example.com", :method => :delete)
)
end
def test_link_tag_using_delete_javascript_and_href
assert_dom_equal(
- "<a href='\#' onclick=\"var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = 'http://www.example.com';var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);f.submit();return false;\">Destroy</a>",
+ "<a href='\#' data-url='http://www.example.com' rel=\"nofollow\" data-method=\"delete\">Destroy</a>",
link_to("Destroy", "http://www.example.com", :method => :delete, :href => '#')
)
end
def test_link_tag_using_post_javascript_and_confirm
assert_dom_equal(
- "<a href=\"http://www.example.com\" onclick=\"if (confirm('Are you serious?')) { var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;f.submit(); };return false;\">Hello</a>",
+ "<a href=\"http://www.example.com\" data-url='http://www.example.com' data-method=\"post\" data-confirm=\"Are you serious?\">Hello</a>",
link_to("Hello", "http://www.example.com", :method => :post, :confirm => "Are you serious?")
)
end
def test_link_tag_using_delete_javascript_and_href_and_confirm
assert_dom_equal(
- "<a href='\#' onclick=\"if (confirm('Are you serious?')) { var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = 'http://www.example.com';var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);f.submit(); };return false;\">Destroy</a>",
+ "<a href=\"#\" data-url='http://www.example.com' rel=\"nofollow\" data-method=\"delete\" data-confirm=\"Are you serious?\">Destroy</a>",
link_to("Destroy", "http://www.example.com", :method => :delete, :href => '#', :confirm => "Are you serious?"),
"When specifying url, form should be generated with it, but not this.href"
)
diff --git a/activerecord/CHANGELOG b/activerecord/CHANGELOG
index ffff0b7e09..a4fa000964 100644
--- a/activerecord/CHANGELOG
+++ b/activerecord/CHANGELOG
@@ -1,5 +1,7 @@
*Edge*
+* PostgreSQLAdapter: set time_zone to UTC when Base.default_timezone == :utc so that Postgres doesn't incorrectly offset-adjust values inserted into TIMESTAMP WITH TIME ZONE columns. #3777 [Jack Christensen]
+
* Allow relations to be used as scope.
class Item
diff --git a/activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb b/activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb
index 1d52c5ec14..b3ce8c79dd 100644
--- a/activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb
+++ b/activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb
@@ -998,7 +998,7 @@ module ActiveRecord
configure_connection
end
- # Configures the encoding, verbosity, and schema search path of the connection.
+ # Configures the encoding, verbosity, schema search path, and time zone of the connection.
# This is called by #connect and should not be called manually.
def configure_connection
if @config[:encoding]
@@ -1010,6 +1010,10 @@ module ActiveRecord
end
self.client_min_messages = @config[:min_messages] if @config[:min_messages]
self.schema_search_path = @config[:schema_search_path] || @config[:schema_order]
+
+ # If using ActiveRecord's time zone support configure the connection to return
+ # TIMESTAMP WITH ZONE types in UTC.
+ execute("SET time zone 'UTC'") if ActiveRecord::Base.default_timezone == :utc
end
# Returns the current ID of a table's sequence.
diff --git a/activerecord/lib/active_record/connection_adapters/sqlite_adapter.rb b/activerecord/lib/active_record/connection_adapters/sqlite_adapter.rb
index 0a52f3a6a2..29225b83c5 100644
--- a/activerecord/lib/active_record/connection_adapters/sqlite_adapter.rb
+++ b/activerecord/lib/active_record/connection_adapters/sqlite_adapter.rb
@@ -193,20 +193,20 @@ module ActiveRecord
SQL
execute(sql, name).map do |row|
- row[0]
+ row['name']
end
end
def columns(table_name, name = nil) #:nodoc:
table_structure(table_name).map do |field|
- SQLiteColumn.new(field['name'], field['dflt_value'], field['type'], field['notnull'] == "0")
+ SQLiteColumn.new(field['name'], field['dflt_value'], field['type'], field['notnull'].to_i == 0)
end
end
def indexes(table_name, name = nil) #:nodoc:
execute("PRAGMA index_list(#{quote_table_name(table_name)})", name).map do |row|
index = IndexDefinition.new(table_name, row['name'])
- index.unique = row['unique'] != '0'
+ index.unique = row['unique'].to_i != 0
index.columns = execute("PRAGMA index_info('#{index.name}')").map { |col| col['name'] }
index
end
diff --git a/activerecord/lib/active_record/railtie.rb b/activerecord/lib/active_record/railtie.rb
index bc06333f1c..dc80ac4b30 100644
--- a/activerecord/lib/active_record/railtie.rb
+++ b/activerecord/lib/active_record/railtie.rb
@@ -8,7 +8,10 @@ require "rails"
module ActiveRecord
class Railtie < Rails::Railtie
- plugin_name :active_record
+ railtie_name :active_record
+
+ config.generators.orm :active_record, :migration => true,
+ :timestamps => true
rake_tasks do
load "active_record/railties/databases.rake"
@@ -18,6 +21,15 @@ module ActiveRecord
require "active_record/railties/subscriber"
subscriber ActiveRecord::Railties::Subscriber.new
+ initializer "active_record.initialize_timezone" do
+ ActiveRecord::Base.time_zone_aware_attributes = true
+ ActiveRecord::Base.default_timezone = :utc
+ end
+
+ initializer "active_record.logger" do
+ ActiveRecord::Base.logger ||= ::Rails.logger
+ end
+
initializer "active_record.set_configs" do |app|
app.config.active_record.each do |k,v|
ActiveRecord::Base.send "#{k}=", v
@@ -31,11 +43,6 @@ module ActiveRecord
ActiveRecord::Base.establish_connection
end
- initializer "active_record.initialize_timezone" do
- ActiveRecord::Base.time_zone_aware_attributes = true
- ActiveRecord::Base.default_timezone = :utc
- end
-
# Expose database runtime to controller for logging.
initializer "active_record.log_runtime" do |app|
require "active_record/railties/controller_runtime"
@@ -45,9 +52,9 @@ module ActiveRecord
# Setup database middleware after initializers have run
initializer "active_record.initialize_database_middleware" do |app|
middleware = app.config.middleware
- if middleware.include?(ActiveRecord::SessionStore)
- middleware.insert_before ActiveRecord::SessionStore, ActiveRecord::ConnectionAdapters::ConnectionManagement
- middleware.insert_before ActiveRecord::SessionStore, ActiveRecord::QueryCache
+ if middleware.include?("ActiveRecord::SessionStore")
+ middleware.insert_before "ActiveRecord::SessionStore", ActiveRecord::ConnectionAdapters::ConnectionManagement
+ middleware.insert_before "ActiveRecord::SessionStore", ActiveRecord::QueryCache
else
middleware.use ActiveRecord::ConnectionAdapters::ConnectionManagement
middleware.use ActiveRecord::QueryCache
@@ -71,11 +78,6 @@ module ActiveRecord
end
end
- # TODO: ActiveRecord::Base.logger should delegate to its own config.logger
- initializer "active_record.logger" do
- ActiveRecord::Base.logger ||= ::Rails.logger
- end
-
initializer "active_record.i18n_deprecation" do
require 'active_support/i18n'
diff --git a/activerecord/lib/active_record/railties/databases.rake b/activerecord/lib/active_record/railties/databases.rake
index 88974dd786..2ef8676f39 100644
--- a/activerecord/lib/active_record/railties/databases.rake
+++ b/activerecord/lib/active_record/railties/databases.rake
@@ -1,7 +1,7 @@
namespace :db do
task :load_config => :rails_env do
require 'active_record'
- ActiveRecord::Base.configurations = Rails::Configuration.new.database_configuration
+ ActiveRecord::Base.configurations = Rails::Application.config.database_configuration
end
namespace :create do
diff --git a/activerecord/lib/active_record/relation/query_methods.rb b/activerecord/lib/active_record/relation/query_methods.rb
index 8954f2d12b..0266700f66 100644
--- a/activerecord/lib/active_record/relation/query_methods.rb
+++ b/activerecord/lib/active_record/relation/query_methods.rb
@@ -133,8 +133,13 @@ module ActiveRecord
arel = h.is_a?(String) ? arel.having(h) : arel.having(*h)
end
- arel = arel.take(@limit_value) if @limit_value.present?
- arel = arel.skip(@offset_value) if @offset_value.present?
+ if defined?(@limit_value) && @limit_value.present?
+ arel = arel.take(@limit_value)
+ end
+
+ if defined?(@offset_value) && @offset_value.present?
+ arel = arel.skip(@offset_value)
+ end
@group_values.uniq.each do |g|
arel = arel.group(g) if g.present?
@@ -157,7 +162,12 @@ module ActiveRecord
arel = arel.project(quoted_table_name + '.*')
end
- arel = @from_value.present? ? arel.from(@from_value) : arel.from(quoted_table_name)
+ arel =
+ if defined?(@from_value) && @from_value.present?
+ arel.from(@from_value)
+ else
+ arel.from(quoted_table_name)
+ end
case @lock_value
when TrueClass
diff --git a/activerecord/test/cases/calculations_test.rb b/activerecord/test/cases/calculations_test.rb
index c3b2e56387..e6d56a7193 100644
--- a/activerecord/test/cases/calculations_test.rb
+++ b/activerecord/test/cases/calculations_test.rb
@@ -288,6 +288,9 @@ class CalculationsTest < ActiveRecord::TestCase
# Oracle adapter returns floating point value 636.0 after SUM
if current_adapter?(:OracleAdapter)
assert_equal 636, Account.sum("2 * credit_limit")
+ elsif current_adapter?(:SQLite3Adapter)
+ # Future versions of the SQLite3 adapter will return a number
+ assert_equal 636, Account.sum("2 * credit_limit").to_i
else
assert_equal '636', Account.sum("2 * credit_limit")
end
diff --git a/activerecord/test/cases/datatype_test_postgresql.rb b/activerecord/test/cases/datatype_test_postgresql.rb
index 88fb6f7384..9454b6e059 100644
--- a/activerecord/test/cases/datatype_test_postgresql.rb
+++ b/activerecord/test/cases/datatype_test_postgresql.rb
@@ -21,6 +21,9 @@ end
class PostgresqlOid < ActiveRecord::Base
end
+class PostgresqlTimestampWithZone < ActiveRecord::Base
+end
+
class PostgresqlDataTypeTest < ActiveRecord::TestCase
self.use_transactional_fixtures = false
@@ -50,6 +53,8 @@ class PostgresqlDataTypeTest < ActiveRecord::TestCase
@connection.execute("INSERT INTO postgresql_oids (obj_id) VALUES (1234)")
@first_oid = PostgresqlOid.find(1)
+
+ @connection.execute("INSERT INTO postgresql_timestamp_with_zones (time) VALUES ('2010-01-01 10:00:00-1')")
end
def test_data_type_of_array_types
@@ -201,4 +206,38 @@ class PostgresqlDataTypeTest < ActiveRecord::TestCase
assert @first_oid.reload
assert_equal @first_oid.obj_id, new_value
end
+
+ def test_timestamp_with_zone_values_with_rails_time_zone_support
+ old_tz = ActiveRecord::Base.time_zone_aware_attributes
+ old_default_tz = ActiveRecord::Base.default_timezone
+
+ ActiveRecord::Base.time_zone_aware_attributes = true
+ ActiveRecord::Base.default_timezone = :utc
+
+ @connection.reconnect!
+
+ @first_timestamp_with_zone = PostgresqlTimestampWithZone.find(1)
+ assert_equal Time.utc(2010,1,1, 11,0,0), @first_timestamp_with_zone.time
+ ensure
+ ActiveRecord::Base.default_timezone = old_default_tz
+ ActiveRecord::Base.time_zone_aware_attributes = old_tz
+ @connection.reconnect!
+ end
+
+ def test_timestamp_with_zone_values_without_rails_time_zone_support
+ old_tz = ActiveRecord::Base.time_zone_aware_attributes
+ old_default_tz = ActiveRecord::Base.default_timezone
+
+ ActiveRecord::Base.time_zone_aware_attributes = false
+ ActiveRecord::Base.default_timezone = :local
+
+ @connection.reconnect!
+
+ @first_timestamp_with_zone = PostgresqlTimestampWithZone.find(1)
+ assert_equal Time.utc(2010,1,1, 11,0,0), @first_timestamp_with_zone.time
+ ensure
+ ActiveRecord::Base.default_timezone = old_default_tz
+ ActiveRecord::Base.time_zone_aware_attributes = old_tz
+ @connection.reconnect!
+ end
end
diff --git a/activerecord/test/cases/query_cache_test.rb b/activerecord/test/cases/query_cache_test.rb
index 2af6a56b6a..3710f8e40b 100644
--- a/activerecord/test/cases/query_cache_test.rb
+++ b/activerecord/test/cases/query_cache_test.rb
@@ -49,10 +49,16 @@ class QueryCacheTest < ActiveRecord::TestCase
end
def test_cache_does_not_wrap_string_results_in_arrays
+ require 'sqlite3/version' if current_adapter?(:SQLite3Adapter)
+
Task.cache do
# Oracle adapter returns count() as Fixnum or Float
if current_adapter?(:OracleAdapter)
assert Task.connection.select_value("SELECT count(*) AS count_all FROM tasks").is_a?(Numeric)
+ elsif current_adapter?(:SQLite3Adapter) && SQLite3::Version::VERSION > '1.2.5'
+ # Future versions of the sqlite3 adapter will return numeric
+ assert_instance_of Fixnum,
+ Task.connection.select_value("SELECT count(*) AS count_all FROM tasks")
else
assert_instance_of String, Task.connection.select_value("SELECT count(*) AS count_all FROM tasks")
end
diff --git a/activerecord/test/schema/postgresql_specific_schema.rb b/activerecord/test/schema/postgresql_specific_schema.rb
index 3d8911bfe9..065d8cfe98 100644
--- a/activerecord/test/schema/postgresql_specific_schema.rb
+++ b/activerecord/test/schema/postgresql_specific_schema.rb
@@ -1,7 +1,7 @@
ActiveRecord::Schema.define do
%w(postgresql_arrays postgresql_moneys postgresql_numbers postgresql_times postgresql_network_addresses postgresql_bit_strings
- postgresql_oids postgresql_xml_data_type defaults geometrics).each do |table_name|
+ postgresql_oids postgresql_xml_data_type defaults geometrics postgresql_timestamp_with_zones).each do |table_name|
execute "DROP TABLE IF EXISTS #{quote_table_name table_name}"
end
@@ -100,6 +100,13 @@ _SQL
obj_id OID
);
_SQL
+
+ execute <<_SQL
+ CREATE TABLE postgresql_timestamp_with_zones (
+ id SERIAL PRIMARY KEY,
+ time TIMESTAMP WITH TIME ZONE
+ );
+_SQL
begin
execute <<_SQL
diff --git a/activeresource/lib/active_resource/railtie.rb b/activeresource/lib/active_resource/railtie.rb
index 1b9307d472..7e35fdc0eb 100644
--- a/activeresource/lib/active_resource/railtie.rb
+++ b/activeresource/lib/active_resource/railtie.rb
@@ -3,9 +3,15 @@ require "rails"
module ActiveResource
class Railtie < Rails::Railtie
- plugin_name :active_resource
+ railtie_name :active_resource
require "active_resource/railties/subscriber"
subscriber ActiveResource::Railties::Subscriber.new
+
+ initializer "active_resource.set_configs" do |app|
+ app.config.active_resource.each do |k,v|
+ ActiveResource::Base.send "#{k}=", v
+ end
+ end
end
end \ No newline at end of file
diff --git a/activeresource/lib/active_resource/validations.rb b/activeresource/lib/active_resource/validations.rb
index 7b2382bd8c..4774c6dd22 100644
--- a/activeresource/lib/active_resource/validations.rb
+++ b/activeresource/lib/active_resource/validations.rb
@@ -101,10 +101,10 @@ module ActiveResource
# Loads the set of remote errors into the object's Errors based on the
# content-type of the error-block received
def load_remote_errors(remote_errors, save_cache = false ) #:nodoc:
- case remote_errors.response['Content-Type']
- when /xml/
+ case self.class.format
+ when ActiveResource::Formats[:xml]
errors.from_xml(remote_errors.response.body, save_cache)
- when /json/
+ when ActiveResource::Formats[:json]
errors.from_json(remote_errors.response.body, save_cache)
end
end
diff --git a/activeresource/test/cases/base_errors_test.rb b/activeresource/test/cases/base_errors_test.rb
index 1eb7765132..b4fd75fba3 100644
--- a/activeresource/test/cases/base_errors_test.rb
+++ b/activeresource/test/cases/base_errors_test.rb
@@ -69,6 +69,19 @@ class BaseErrorsTest < Test::Unit::TestCase
end
end
+ def test_should_mark_as_invalid_when_content_type_is_unavailable_in_response_header
+ ActiveResource::HttpMock.respond_to do |mock|
+ mock.post "/people.xml", {}, %q(<?xml version="1.0" encoding="UTF-8"?><errors><error>Age can't be blank</error><error>Name can't be blank</error><error>Name must start with a letter</error><error>Person quota full for today.</error></errors>), 422, {}
+ mock.post "/people.json", {}, %q({"errors":["Age can't be blank","Name can't be blank","Name must start with a letter","Person quota full for today."]}), 422, {}
+ end
+
+ [ :json, :xml ].each do |format|
+ invalid_user_using_format(format) do
+ assert !@person.valid?
+ end
+ end
+ end
+
private
def invalid_user_using_format(mime_type_reference)
previous_format = Person.format
diff --git a/activesupport/CHANGELOG b/activesupport/CHANGELOG
index 87ec6f2a2c..787fa26e44 100644
--- a/activesupport/CHANGELOG
+++ b/activesupport/CHANGELOG
@@ -1,4 +1,12 @@
-*Edge*
+*Rails 3.0 (pending)*
+
+* Time#- with a DateTime argument behaves the same as with a Time argument, i.e. returns the difference between self and arg as a Float #3476 [Geoff Buesing]
+
+* YAML serialization for OrderedHash. #3608 [Gregor Schmidt]
+
+* Update bundled TZInfo to v0.3.16 [Geoff Buesing]
+
+* Georgetown TimeZone is now mapped to "America/Guyana" instead of "America/Argentina/San_Juan" #1821 [Geoff Buesing, Reuben Sivan]
* Changed the default ActiveSupport.use_standard_json_time_format from false to true and
ActiveSupport.escape_html_entities_in_json from true to false to match previously announced Rails 3 defaults [DHH]
diff --git a/activesupport/Rakefile b/activesupport/Rakefile
index 08af1d6fca..03ab3b2760 100644
--- a/activesupport/Rakefile
+++ b/activesupport/Rakefile
@@ -41,7 +41,6 @@ Rake::RDocTask.new { |rdoc|
rdoc.rdoc_files.include('README', 'CHANGELOG')
rdoc.rdoc_files.include('lib/active_support.rb')
rdoc.rdoc_files.include('lib/active_support/**/*.rb')
- rdoc.rdoc_files.exclude('lib/active_support/vendor/*')
}
spec = eval(File.read('activesupport.gemspec'))
@@ -74,102 +73,3 @@ task :release => [ :package ] do
rubyforge.login
rubyforge.add_release(PKG_NAME, PKG_NAME, "REL #{PKG_VERSION}", *packages)
end
-
-
-$LOAD_PATH.unshift "#{File.dirname(__FILE__)}/lib"
-require 'active_support/values/time_zone'
-
-namespace :tzinfo do
- desc "Update bundled tzinfo gem. Only copies the subset of classes and definitions required to support Rails time zone features."
- task :update => ['tzinfo:copy_classes', 'tzinfo:copy_definitions'] do
- Rake::Task['tzinfo:cleanup_tmp'].invoke
- puts <<-EOV
- *** FINAL TZINFO BUNDLING STEPS ***
-
- 1. Update TZInfo version in lib/active_support/vendor.rb
- 2. gem uninstall tzinfo on local system before running tests, to ensure tests are running against bundled version
-
- If a test fails because a particular zone can't be found, it's likely because the TZInfo identifier in the
- ActiveSupport::TimeZone::MAPPING hash is referencing a linked timezone instead of referencing the timezone directly.
- In this case, just change the MAPPING value to the correct identifier, and unpack TZInfo again.
- EOV
- end
-
- task :unpack_gem do
- mkdir_p "tmp"
- cd "tmp"
- sh "gem unpack --version #{ENV['VERSION'] || "'> 0'"} tzinfo"
- cd ".."
- end
-
- task :copy_classes => :unpack_gem do
- mkdir_p "#{destination_path}/lib/tzinfo"
- cp "#{tmp_path}/lib/tzinfo.rb", "#{destination_path}/lib"
- comment_requires_for_excluded_classes!('lib/tzinfo.rb')
- files = FileList["#{tmp_path}/lib/tzinfo/*.rb"]
- files.each do |file|
- filename = File.basename(file)
- unless excluded_classes.include? filename.sub(/.rb$/, '')
- cp "#{tmp_path}/lib/tzinfo/#{filename}", "#{destination_path}/lib/tzinfo"
- comment_requires_for_excluded_classes!("lib/tzinfo/#{filename}")
- end
- end
- end
-
- task :copy_definitions => :unpack_gem do
- definitions_path = "#{destination_path}/lib/tzinfo/definitions/"
- mkdir_p definitions_path
- ActiveSupport::TimeZone::MAPPING.values.each do |zone|
- subdir = nil
- if /\// === zone
- subdir = zone.sub(/\w+$/, '')
- mkdir_p "#{definitions_path}/#{subdir}"
- end
- cp "#{tmp_path}/lib/tzinfo/definitions/#{zone}.rb", "#{definitions_path}/#{subdir}"
- end
- end
-
- task :cleanup_tmp do
- rm_rf "tmp"
- end
-
- def comment_requires_for_excluded_classes!(file)
- lines = open("#{destination_path}/#{file}") {|f| f.readlines}
- updated = false
-
- new_lines = []
- lines.each do |line|
- if Regexp.new("require 'tzinfo/(#{excluded_classes.join('|')})'") === line
- updated = true
- new_lines << "# #{line}"
- else
- new_lines << line
- end
- end
-
- if updated
- open("#{destination_path}/#{file}", "w") {|f| f.write(new_lines.join)}
- end
- end
-
- def version
- ENV['VERSION'] ||= get_unpacked_version
- end
-
- def get_unpacked_version
- m = (FileList["tmp/tzinfo-*"].to_s.match /\d+\.\d+\.\d+/)
- m ? m[0] : raise(LoadError, "TZInfo gem must be installed locally. `gem install tzinfo` and try again")
- end
-
- def tmp_path
- "tmp/tzinfo-#{version}"
- end
-
- def destination_path
- "lib/active_support/vendor/tzinfo-#{version}"
- end
-
- def excluded_classes
- %w(country country_index_definition country_info country_timezone timezone_index_definition timezone_proxy tzdataparser)
- end
-end
diff --git a/activesupport/activesupport.gemspec b/activesupport/activesupport.gemspec
index 8b9dd55b53..19cdbaa41a 100644
--- a/activesupport/activesupport.gemspec
+++ b/activesupport/activesupport.gemspec
@@ -7,6 +7,9 @@ Gem::Specification.new do |s|
s.description = %q{Utility library which carries commonly used classes and goodies from the Rails framework}
s.add_dependency('i18n', '~> 0.3.0')
+ s.add_dependency('tzinfo', '~> 0.3.16')
+ s.add_dependency('builder', '~> 2.1.2')
+ s.add_dependency('memcache-client', '~> 1.7.5')
s.files = Dir['CHANGELOG', 'README', 'lib/**/*']
s.require_path = 'lib'
diff --git a/activesupport/lib/active_support.rb b/activesupport/lib/active_support.rb
index 51ec87f329..833ae351b9 100644
--- a/activesupport/lib/active_support.rb
+++ b/activesupport/lib/active_support.rb
@@ -69,5 +69,3 @@ module ActiveSupport
autoload :TestCase
end
-
-require 'active_support/vendor'
diff --git a/activesupport/lib/active_support/core_ext/array.rb b/activesupport/lib/active_support/core_ext/array.rb
index b583c7533e..4688468a8f 100644
--- a/activesupport/lib/active_support/core_ext/array.rb
+++ b/activesupport/lib/active_support/core_ext/array.rb
@@ -1,5 +1,6 @@
require 'active_support/core_ext/array/wrap'
require 'active_support/core_ext/array/access'
+require 'active_support/core_ext/array/uniq_by'
require 'active_support/core_ext/array/conversions'
require 'active_support/core_ext/array/extract_options'
require 'active_support/core_ext/array/grouping'
diff --git a/activesupport/lib/active_support/core_ext/array/conversions.rb b/activesupport/lib/active_support/core_ext/array/conversions.rb
index 7fcef38372..814567a5a6 100644
--- a/activesupport/lib/active_support/core_ext/array/conversions.rb
+++ b/activesupport/lib/active_support/core_ext/array/conversions.rb
@@ -13,19 +13,6 @@ class Array
default_two_words_connector = I18n.translate(:'support.array.two_words_connector', :locale => options[:locale])
default_last_word_connector = I18n.translate(:'support.array.last_word_connector', :locale => options[:locale])
- # Try to emulate to_sentences previous to 2.3
- if options.has_key?(:connector) || options.has_key?(:skip_last_comma)
- ::ActiveSupport::Deprecation.warn(":connector has been deprecated. Use :words_connector instead", caller) if options.has_key? :connector
- ::ActiveSupport::Deprecation.warn(":skip_last_comma has been deprecated. Use :last_word_connector instead", caller) if options.has_key? :skip_last_comma
-
- skip_last_comma = options.delete :skip_last_comma
- if connector = options.delete(:connector)
- options[:last_word_connector] ||= skip_last_comma ? connector : ", #{connector}"
- else
- options[:last_word_connector] ||= skip_last_comma ? default_two_words_connector : default_last_word_connector
- end
- end
-
options.assert_valid_keys(:words_connector, :two_words_connector, :last_word_connector, :locale)
options.reverse_merge! :words_connector => default_words_connector, :two_words_connector => default_two_words_connector, :last_word_connector => default_last_word_connector
diff --git a/activesupport/lib/active_support/core_ext/array/uniq_by.rb b/activesupport/lib/active_support/core_ext/array/uniq_by.rb
new file mode 100644
index 0000000000..a09b2302fd
--- /dev/null
+++ b/activesupport/lib/active_support/core_ext/array/uniq_by.rb
@@ -0,0 +1,17 @@
+class Array
+ # Return an unique array based on the criteria given as a proc.
+ #
+ # [1, 2, 3, 4].uniq_by { |i| i.odd? }
+ # #=> [1, 2]
+ #
+ def uniq_by
+ hash, array = {}, []
+ each { |i| hash[yield(i)] ||= (array << i) }
+ array
+ end
+
+ # Same as uniq_by, but modifies self.
+ def uniq_by!
+ replace(uniq_by{ |i| yield(i) })
+ end
+end
diff --git a/activesupport/lib/active_support/core_ext/class.rb b/activesupport/lib/active_support/core_ext/class.rb
index 44ad6c8c08..62df7d8b82 100644
--- a/activesupport/lib/active_support/core_ext/class.rb
+++ b/activesupport/lib/active_support/core_ext/class.rb
@@ -1,4 +1,3 @@
require 'active_support/core_ext/class/attribute_accessors'
require 'active_support/core_ext/class/inheritable_attributes'
-require 'active_support/core_ext/class/removal'
require 'active_support/core_ext/class/delegating_attributes'
diff --git a/activesupport/lib/active_support/core_ext/class/removal.rb b/activesupport/lib/active_support/core_ext/class/removal.rb
deleted file mode 100644
index 652be4ed78..0000000000
--- a/activesupport/lib/active_support/core_ext/class/removal.rb
+++ /dev/null
@@ -1,57 +0,0 @@
-require 'active_support/core_ext/object/extending'
-require 'active_support/core_ext/module/introspection'
-
-class Class #:nodoc:
-
- def reachable?
- eval("defined?(::#{self}) && ::#{self}.equal?(self)")
- end
-
- # Unassociates the class with its subclasses and removes the subclasses
- # themselves.
- #
- # Integer.remove_subclasses # => [Bignum, Fixnum]
- # Fixnum # => NameError: uninitialized constant Fixnum
- def remove_subclasses
- Object.remove_subclasses_of(self)
- end
-
- # Returns an array with the names of the subclasses of +self+ as strings.
- #
- # Integer.subclasses # => ["Bignum", "Fixnum"]
- def subclasses
- Object.subclasses_of(self).map { |o| o.to_s }
- end
-
- # Removes the classes in +klasses+ from their parent module.
- #
- # Ordinary classes belong to some module via a constant. This method computes
- # that constant name from the class name and removes it from the module it
- # belongs to.
- #
- # Object.remove_class(Integer) # => [Integer]
- # Integer # => NameError: uninitialized constant Integer
- #
- # Take into account that in general the class object could be still stored
- # somewhere else.
- #
- # i = Integer # => Integer
- # Object.remove_class(Integer) # => [Integer]
- # Integer # => NameError: uninitialized constant Integer
- # i.subclasses # => ["Bignum", "Fixnum"]
- # Fixnum.superclass # => Integer
- def remove_class(*klasses)
- klasses.flatten.each do |klass|
- # Skip this class if there is nothing bound to this name
- next unless defined?(klass.name)
-
- basename = klass.to_s.split("::").last
- parent = klass.parent
-
- # Skip this class if it does not match the current one bound to this name
- next unless parent.const_defined?(basename) && klass = parent.const_get(basename)
-
- parent.instance_eval { remove_const basename } unless parent == klass
- end
- end
-end
diff --git a/activesupport/lib/active_support/core_ext/hash/deep_merge.rb b/activesupport/lib/active_support/core_ext/hash/deep_merge.rb
index 24d0a2a481..af771c86ff 100644
--- a/activesupport/lib/active_support/core_ext/hash/deep_merge.rb
+++ b/activesupport/lib/active_support/core_ext/hash/deep_merge.rb
@@ -1,17 +1,16 @@
class Hash
# Returns a new hash with +self+ and +other_hash+ merged recursively.
def deep_merge(other_hash)
- target = dup
- other_hash.each_pair do |k,v|
- tv = target[k]
- target[k] = tv.is_a?(Hash) && v.is_a?(Hash) ? tv.deep_merge(v) : v
- end
- target
+ dup.deep_merge!(other_hash)
end
# Returns a new hash with +self+ and +other_hash+ merged recursively.
# Modifies the receiver in place.
def deep_merge!(other_hash)
- replace(deep_merge(other_hash))
+ other_hash.each_pair do |k,v|
+ tv = self[k]
+ self[k] = tv.is_a?(Hash) && v.is_a?(Hash) ? tv.deep_merge(v) : v
+ end
+ self
end
end
diff --git a/activesupport/lib/active_support/core_ext/hash/keys.rb b/activesupport/lib/active_support/core_ext/hash/keys.rb
index ecd63293b4..045a6944fa 100644
--- a/activesupport/lib/active_support/core_ext/hash/keys.rb
+++ b/activesupport/lib/active_support/core_ext/hash/keys.rb
@@ -1,10 +1,7 @@
class Hash
# Return a new hash with all keys converted to strings.
def stringify_keys
- inject({}) do |options, (key, value)|
- options[key.to_s] = value
- options
- end
+ dup.stringify_keys!
end
# Destructively convert all keys to strings.
@@ -18,16 +15,16 @@ class Hash
# Return a new hash with all keys converted to symbols, as long as
# they respond to +to_sym+.
def symbolize_keys
- inject({}) do |options, (key, value)|
- options[(key.to_sym rescue key) || key] = value
- options
- end
+ dup.symbolize_keys!
end
# Destructively convert all keys to symbols, as long as they respond
# to +to_sym+.
def symbolize_keys!
- self.replace(self.symbolize_keys)
+ keys.each do |key|
+ self[(key.to_sym rescue key) || key] = delete(key)
+ end
+ self
end
alias_method :to_options, :symbolize_keys
diff --git a/activesupport/lib/active_support/core_ext/object.rb b/activesupport/lib/active_support/core_ext/object.rb
index 04e8f06b3d..08e07a5b24 100644
--- a/activesupport/lib/active_support/core_ext/object.rb
+++ b/activesupport/lib/active_support/core_ext/object.rb
@@ -4,7 +4,6 @@ require 'active_support/core_ext/object/duplicable'
require 'active_support/core_ext/object/try'
require 'active_support/core_ext/object/conversions'
-require 'active_support/core_ext/object/extending'
require 'active_support/core_ext/object/instance_variables'
require 'active_support/core_ext/object/metaclass'
require 'active_support/core_ext/object/misc'
diff --git a/activesupport/lib/active_support/core_ext/object/extending.rb b/activesupport/lib/active_support/core_ext/object/extending.rb
deleted file mode 100644
index b8b6970382..0000000000
--- a/activesupport/lib/active_support/core_ext/object/extending.rb
+++ /dev/null
@@ -1,63 +0,0 @@
-require 'active_support/core_ext/class/removal'
-require 'active_support/core_ext/object/blank'
-
-class Class
- # Rubinius
- if defined?(Class.__subclasses__)
- def descendents
- subclasses = []
- __subclasses__.each {|k| subclasses << k; subclasses.concat k.descendents }
- subclasses
- end
- else
- # MRI
- begin
- ObjectSpace.each_object(Class.new) {}
-
- def descendents
- subclasses = []
- ObjectSpace.each_object(class << self; self; end) do |k|
- subclasses << k unless k == self
- end
- subclasses
- end
- # JRuby
- rescue StandardError
- def descendents
- subclasses = []
- ObjectSpace.each_object(Class) do |k|
- subclasses << k if k < self
- end
- subclasses.uniq!
- subclasses
- end
- end
- end
-end
-
-class Object
- def remove_subclasses_of(*superclasses) #:nodoc:
- Class.remove_class(*subclasses_of(*superclasses))
- end
-
- # Exclude this class unless it's a subclass of our supers and is defined.
- # We check defined? in case we find a removed class that has yet to be
- # garbage collected. This also fails for anonymous classes -- please
- # submit a patch if you have a workaround.
- def subclasses_of(*superclasses) #:nodoc:
- subclasses = []
- superclasses.each do |klass|
- subclasses.concat klass.descendents.select {|k| k.name.blank? || k.reachable?}
- end
- subclasses
- end
-
- def extended_by #:nodoc:
- ancestors = class << self; ancestors end
- ancestors.select { |mod| mod.class == Module } - [ Object, Kernel ]
- end
-
- def extend_with_included_modules_from(object) #:nodoc:
- object.extended_by.each { |mod| extend mod }
- end
-end
diff --git a/activesupport/lib/active_support/core_ext/time/calculations.rb b/activesupport/lib/active_support/core_ext/time/calculations.rb
index 703b89ffd0..98906bc5c0 100644
--- a/activesupport/lib/active_support/core_ext/time/calculations.rb
+++ b/activesupport/lib/active_support/core_ext/time/calculations.rb
@@ -259,7 +259,7 @@ class Time
# are coerced into values that Time#- will recognize
def minus_with_coercion(other)
other = other.comparable_time if other.respond_to?(:comparable_time)
- minus_without_coercion(other)
+ other.is_a?(DateTime) ? to_f - other.to_f : minus_without_coercion(other)
end
alias_method :minus_without_coercion, :-
alias_method :-, :minus_with_coercion
diff --git a/activesupport/lib/active_support/ordered_hash.rb b/activesupport/lib/active_support/ordered_hash.rb
index b492648610..57ead35827 100644
--- a/activesupport/lib/active_support/ordered_hash.rb
+++ b/activesupport/lib/active_support/ordered_hash.rb
@@ -1,8 +1,11 @@
+require 'yaml'
+
# OrderedHash is namespaced to prevent conflicts with other implementations
module ActiveSupport
# Hash is ordered in Ruby 1.9!
if RUBY_VERSION >= '1.9'
- OrderedHash = ::Hash
+ class OrderedHash < ::Hash #:nodoc:
+ end
else
class OrderedHash < Hash #:nodoc:
def initialize(*args, &block)
@@ -138,4 +141,24 @@ module ActiveSupport
end
end
end
+
+ class OrderedHash #:nodoc:
+ def to_yaml_type
+ "!tag:yaml.org,2002:omap"
+ end
+
+ def to_yaml(opts = {})
+ YAML.quick_emit(self, opts) do |out|
+ out.seq(taguri, to_yaml_style) do |seq|
+ each do |k, v|
+ seq.add(k => v)
+ end
+ end
+ end
+ end
+ end
+
+ YAML.add_builtin_type("omap") do |type, val|
+ ActiveSupport::OrderedHash[val.map(&:to_a).map(&:first)]
+ end
end
diff --git a/activesupport/lib/active_support/railtie.rb b/activesupport/lib/active_support/railtie.rb
new file mode 100644
index 0000000000..c8d8b85000
--- /dev/null
+++ b/activesupport/lib/active_support/railtie.rb
@@ -0,0 +1,64 @@
+require "active_support"
+require "rails"
+
+module ActiveSupport
+ class Railtie < Rails::Railtie
+ railtie_name :active_support
+
+ # Loads support for "whiny nil" (noisy warnings when methods are invoked
+ # on +nil+ values) if Configuration#whiny_nils is true.
+ initializer "active_support.initialize_whiny_nils" do |app|
+ require 'active_support/whiny_nil' if app.config.whiny_nils
+ end
+
+ # Sets the default value for Time.zone
+ # If assigned value cannot be matched to a TimeZone, an exception will be raised.
+ initializer "active_support.initialize_time_zone" do |app|
+ require 'active_support/core_ext/time/zones'
+ zone_default = Time.__send__(:get_zone, app.config.time_zone)
+
+ unless zone_default
+ raise \
+ 'Value assigned to config.time_zone not recognized.' +
+ 'Run "rake -D time" for a list of tasks for finding appropriate time zone names.'
+ end
+
+ Time.zone_default = zone_default
+ end
+ end
+end
+
+module I18n
+ class Railtie < Rails::Railtie
+ railtie_name :i18n
+
+ # Initialize I18n load paths to an array
+ config.i18n.engines_load_path = []
+ config.i18n.load_path = []
+
+ initializer "i18n.initialize" do
+ require 'active_support/i18n'
+
+ ActionDispatch::Callbacks.to_prepare do
+ I18n.reload!
+ end
+ end
+
+ # Set the i18n configuration from config.i18n but special-case for
+ # the load_path which should be appended to what's already set instead of overwritten.
+ config.after_initialize do |app|
+ app.config.i18n.each do |setting, value|
+ case setting
+ when :engines_load_path
+ app.config.i18n.load_path.unshift(*value)
+ when :load_path
+ I18n.load_path += value
+ else
+ I18n.send("#{setting}=", value)
+ end
+ end
+
+ I18n.reload!
+ end
+ end
+end \ No newline at end of file
diff --git a/activesupport/lib/active_support/values/time_zone.rb b/activesupport/lib/active_support/values/time_zone.rb
index 245d3ce051..4db3dd1705 100644
--- a/activesupport/lib/active_support/values/time_zone.rb
+++ b/activesupport/lib/active_support/values/time_zone.rb
@@ -55,7 +55,7 @@ module ActiveSupport
"Newfoundland" => "America/St_Johns",
"Brasilia" => "America/Sao_Paulo",
"Buenos Aires" => "America/Argentina/Buenos_Aires",
- "Georgetown" => "America/Argentina/San_Juan",
+ "Georgetown" => "America/Guyana",
"Greenland" => "America/Godthab",
"Mid-Atlantic" => "Atlantic/South_Georgia",
"Azores" => "Atlantic/Azores",
@@ -323,9 +323,9 @@ module ActiveSupport
[-18_000, "Eastern Time (US & Canada)", "Indiana (East)", "Bogota",
"Lima", "Quito" ],
[-16_200, "Caracas" ],
- [-14_400, "Atlantic Time (Canada)", "La Paz", "Santiago" ],
+ [-14_400, "Atlantic Time (Canada)", "Georgetown", "La Paz", "Santiago" ],
[-12_600, "Newfoundland" ],
- [-10_800, "Brasilia", "Buenos Aires", "Georgetown", "Greenland" ],
+ [-10_800, "Brasilia", "Buenos Aires", "Greenland" ],
[ -7_200, "Mid-Atlantic" ],
[ -3_600, "Azores", "Cape Verde Is." ],
[ 0, "Dublin", "Edinburgh", "Lisbon", "London", "Casablanca",
diff --git a/activesupport/lib/active_support/vendor.rb b/activesupport/lib/active_support/vendor.rb
deleted file mode 100644
index 1e46491d83..0000000000
--- a/activesupport/lib/active_support/vendor.rb
+++ /dev/null
@@ -1,19 +0,0 @@
-require 'pathname'
-
-def ActiveSupport.requirable?(file)
- $LOAD_PATH.any? { |p| Dir.glob("#{p}/#{file}.*").any? }
-end
-
-[%w(builder 2.1.2), %w(memcache-client 1.7.5), %w(tzinfo 0.3.15)].each do |lib, version|
- # If the lib is not already requirable
- unless ActiveSupport.requirable? lib
- # Try to activate a gem ~> satisfying the requested version first.
- begin
- gem lib, ">= #{version}"
- # Use the vendored lib if the gem's missing or we aren't using RubyGems.
- rescue LoadError, NoMethodError
- # There could be symlinks
- $LOAD_PATH.unshift Pathname.new(__FILE__).dirname.join("vendor/#{lib}-#{version}/lib").realpath.to_s
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/builder-2.1.2/lib/blankslate.rb b/activesupport/lib/active_support/vendor/builder-2.1.2/lib/blankslate.rb
deleted file mode 100644
index da6034d9c4..0000000000
--- a/activesupport/lib/active_support/vendor/builder-2.1.2/lib/blankslate.rb
+++ /dev/null
@@ -1,113 +0,0 @@
-#!/usr/bin/env ruby
-#--
-# Copyright 2004, 2006 by Jim Weirich (jim@weirichhouse.org).
-# All rights reserved.
-
-# Permission is granted for use, copying, modification, distribution,
-# and distribution of modified versions of this work as long as the
-# above copyright notice is included.
-#++
-
-######################################################################
-# BlankSlate provides an abstract base class with no predefined
-# methods (except for <tt>\_\_send__</tt> and <tt>\_\_id__</tt>).
-# BlankSlate is useful as a base class when writing classes that
-# depend upon <tt>method_missing</tt> (e.g. dynamic proxies).
-#
-class BlankSlate
- class << self
-
- # Hide the method named +name+ in the BlankSlate class. Don't
- # hide +instance_eval+ or any method beginning with "__".
- def hide(name)
- if instance_methods.include?(name.to_s) and
- name !~ /^(__|instance_eval)/
- @hidden_methods ||= {}
- @hidden_methods[name.to_sym] = instance_method(name)
- undef_method name
- end
- end
-
- def find_hidden_method(name)
- @hidden_methods ||= {}
- @hidden_methods[name] || superclass.find_hidden_method(name)
- end
-
- # Redefine a previously hidden method so that it may be called on a blank
- # slate object.
- def reveal(name)
- bound_method = nil
- unbound_method = find_hidden_method(name)
- fail "Don't know how to reveal method '#{name}'" unless unbound_method
- define_method(name) do |*args|
- bound_method ||= unbound_method.bind(self)
- bound_method.call(*args)
- end
- end
- end
-
- instance_methods.each { |m| hide(m) }
-end
-
-######################################################################
-# Since Ruby is very dynamic, methods added to the ancestors of
-# BlankSlate <em>after BlankSlate is defined</em> will show up in the
-# list of available BlankSlate methods. We handle this by defining a
-# hook in the Object and Kernel classes that will hide any method
-# defined after BlankSlate has been loaded.
-#
-module Kernel
- class << self
- alias_method :blank_slate_method_added, :method_added
-
- # Detect method additions to Kernel and remove them in the
- # BlankSlate class.
- def method_added(name)
- result = blank_slate_method_added(name)
- return result if self != Kernel
- BlankSlate.hide(name)
- result
- end
- end
-end
-
-######################################################################
-# Same as above, except in Object.
-#
-class Object
- class << self
- alias_method :blank_slate_method_added, :method_added
-
- # Detect method additions to Object and remove them in the
- # BlankSlate class.
- def method_added(name)
- result = blank_slate_method_added(name)
- return result if self != Object
- BlankSlate.hide(name)
- result
- end
-
- def find_hidden_method(name)
- nil
- end
- end
-end
-
-######################################################################
-# Also, modules included into Object need to be scanned and have their
-# instance methods removed from blank slate. In theory, modules
-# included into Kernel would have to be removed as well, but a
-# "feature" of Ruby prevents late includes into modules from being
-# exposed in the first place.
-#
-class Module
- alias blankslate_original_append_features append_features
- def append_features(mod)
- result = blankslate_original_append_features(mod)
- return result if mod != Object
- instance_methods.each do |name|
- BlankSlate.hide(name)
- end
- result
- end
-end \ No newline at end of file
diff --git a/activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder.rb b/activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder.rb
deleted file mode 100644
index 9719277669..0000000000
--- a/activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder.rb
+++ /dev/null
@@ -1,13 +0,0 @@
-#!/usr/bin/env ruby
-
-#--
-# Copyright 2004 by Jim Weirich (jim@weirichhouse.org).
-# All rights reserved.
-
-# Permission is granted for use, copying, modification, distribution,
-# and distribution of modified versions of this work as long as the
-# above copyright notice is included.
-#++
-
-require 'builder/xmlmarkup'
-require 'builder/xmlevents'
diff --git a/activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/blankslate.rb b/activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/blankslate.rb
deleted file mode 100644
index 2935b6f1d1..0000000000
--- a/activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/blankslate.rb
+++ /dev/null
@@ -1,20 +0,0 @@
-#!/usr/bin/env ruby
-#--
-# Copyright 2004, 2006 by Jim Weirich (jim@weirichhouse.org).
-# All rights reserved.
-
-# Permission is granted for use, copying, modification, distribution,
-# and distribution of modified versions of this work as long as the
-# above copyright notice is included.
-#++
-
-require 'blankslate'
-
-######################################################################
-# BlankSlate has been promoted to a top level name and is now
-# available as a standalone gem. We make the name available in the
-# Builder namespace for compatibility.
-#
-module Builder
- BlankSlate = ::BlankSlate
-end
diff --git a/activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/css.rb b/activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/css.rb
deleted file mode 100644
index e086a1b132..0000000000
--- a/activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/css.rb
+++ /dev/null
@@ -1,250 +0,0 @@
-#!/usr/bin/env ruby
-#--
-# Copyright 2004, 2005 by Jim Weirich (jim@weirichhouse.org).
-# Copyright 2005 by Scott Barron (scott@elitists.net).
-# All rights reserved.
-#
-# Permission is granted for use, copying, modification, distribution,
-# and distribution of modified versions of this work as long as the
-# above copyright notice is included.
-#
-# Much of this is taken from Jim's work in xmlbase.rb and xmlmarkup.rb.
-# Documentation has also been copied and pasted and modified to reflect
-# that we're building CSS here instead of XML. Jim is conducting the
-# orchestra here and I'm just off in the corner playing a flute.
-#++
-
-# Provide a flexible and easy to use Builder for creating Cascading
-# Style Sheets (CSS).
-
-
-require 'builder/blankslate'
-
-module Builder
-
- # Create a Cascading Style Sheet (CSS) using Ruby.
- #
- # Example usage:
- #
- # css = Builder::CSS.new
- #
- # text_color = '#7F7F7F'
- # preferred_fonts = 'Helvetica, Arial, sans_serif'
- #
- # css.comment! 'This is our stylesheet'
- # css.body {
- # background_color '#FAFAFA'
- # font_size 'small'
- # font_family preferred_fonts
- # color text_color
- # }
- #
- # css.id!('navbar') {
- # width '500px'
- # }
- #
- # css.class!('navitem') {
- # color 'red'
- # }
- #
- # css.a :hover {
- # text_decoration 'underline'
- # }
- #
- # css.div(:id => 'menu') {
- # background 'green'
- # }
- #
- # css.div(:class => 'foo') {
- # background 'red'
- # }
- #
- # This will yield the following stylesheet:
- #
- # /* This is our stylesheet */
- # body {
- # background_color: #FAFAFA;
- # font_size: small;
- # font_family: Helvetica, Arial, sans_serif;
- # color: #7F7F7F;
- # }
- #
- # #navbar {
- # width: 500px;
- # }
- #
- # .navitem {
- # color: red;
- # }
- #
- # a:hover {
- # text_decoration: underline;
- # }
- #
- # div#menu {
- # background: green;
- # }
- #
- # div.foo {
- # background: red;
- # }
- #
- class CSS < BlankSlate
-
- # Create a CSS builder.
- #
- # out:: Object receiving the markup.1 +out+ must respond to
- # <tt><<</tt>.
- # indent:: Number of spaces used for indentation (0 implies no
- # indentation and no line breaks).
- #
- def initialize(indent=2)
- @indent = indent
- @target = []
- @parts = []
- @library = {}
- end
-
- def +(part)
- _join_with_op! '+'
- self
- end
-
- def >>(part)
- _join_with_op! ''
- self
- end
-
- def >(part)
- _join_with_op! '>'
- self
- end
-
- def |(part)
- _join_with_op! ','
- self
- end
-
- # Return the target of the builder
- def target!
- @target * ''
- end
-
- # Create a comment string in the output.
- def comment!(comment_text)
- @target << "/* #{comment_text} */\n"
- end
-
- def id!(arg, &block)
- _start_container('#'+arg.to_s, nil, block_given?)
- _css_block(block) if block
- _unify_block
- self
- end
-
- def class!(arg, &block)
- _start_container('.'+arg.to_s, nil, block_given?)
- _css_block(block) if block
- _unify_block
- self
- end
-
- def store!(sym, &block)
- @library[sym] = block.to_proc
- end
-
- def group!(*args, &block)
- args.each do |arg|
- if arg.is_a?(Symbol)
- instance_eval(&@library[arg])
- else
- instance_eval(&arg)
- end
- _text ', ' unless arg == args.last
- end
- if block
- _css_block(block)
- _unify_block
- end
- end
-
- def method_missing(sym, *args, &block)
- sym = "#{sym}:#{args.shift}" if args.first.kind_of?(Symbol)
- if block
- _start_container(sym, args.first)
- _css_block(block)
- _unify_block
- elsif @in_block
- _indent
- _css_line(sym, *args)
- _newline
- return self
- else
- _start_container(sym, args.first, false)
- _unify_block
- end
- self
- end
-
- # "Cargo culted" from Jim who also "cargo culted" it. See xmlbase.rb.
- def nil?
- false
- end
-
- private
- def _unify_block
- @target << @parts * ''
- @parts = []
- end
-
- def _join_with_op!(op)
- rhs, lhs = @target.pop, @target.pop
- @target << "#{lhs} #{op} #{rhs}"
- end
-
- def _text(text)
- @parts << text
- end
-
- def _css_block(block)
- _newline
- _nested_structures(block)
- _end_container
- _end_block
- end
-
- def _end_block
- _newline
- _newline
- end
-
- def _newline
- _text "\n"
- end
-
- def _indent
- _text ' ' * @indent
- end
-
- def _nested_structures(block)
- @in_block = true
- self.instance_eval(&block)
- @in_block = false
- end
-
- def _start_container(sym, atts = {}, with_bracket = true)
- selector = sym.to_s
- selector << ".#{atts[:class]}" if atts && atts[:class]
- selector << '#' + "#{atts[:id]}" if atts && atts[:id]
- @parts << "#{selector}#{with_bracket ? ' {' : ''}"
- end
-
- def _end_container
- @parts << "}"
- end
-
- def _css_line(sym, *args)
- _text("#{sym.to_s.gsub('_','-')}: #{args * ' '};")
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/xchar.rb b/activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/xchar.rb
deleted file mode 100644
index 8bdbd05899..0000000000
--- a/activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/xchar.rb
+++ /dev/null
@@ -1,115 +0,0 @@
-#!/usr/bin/env ruby
-
-# The XChar library is provided courtesy of Sam Ruby (See
-# http://intertwingly.net/stories/2005/09/28/xchar.rb)
-
-# --------------------------------------------------------------------
-
-# If the Builder::XChar module is not currently defined, fail on any
-# name clashes in standard library classes.
-
-module Builder
- def self.check_for_name_collision(klass, method_name, defined_constant=nil)
- if klass.instance_methods.include?(method_name.to_s)
- fail RuntimeError,
- "Name Collision: Method '#{method_name}' is already defined in #{klass}"
- end
- end
-end
-
-if ! defined?(Builder::XChar)
- Builder.check_for_name_collision(String, "to_xs")
- Builder.check_for_name_collision(Fixnum, "xchr")
-end
-
-######################################################################
-module Builder
-
- ####################################################################
- # XML Character converter, from Sam Ruby:
- # (see http://intertwingly.net/stories/2005/09/28/xchar.rb).
- #
- module XChar # :nodoc:
-
- # See
- # http://intertwingly.net/stories/2004/04/14/i18n.html#CleaningWindows
- # for details.
- CP1252 = { # :nodoc:
- 128 => 8364, # euro sign
- 130 => 8218, # single low-9 quotation mark
- 131 => 402, # latin small letter f with hook
- 132 => 8222, # double low-9 quotation mark
- 133 => 8230, # horizontal ellipsis
- 134 => 8224, # dagger
- 135 => 8225, # double dagger
- 136 => 710, # modifier letter circumflex accent
- 137 => 8240, # per mille sign
- 138 => 352, # latin capital letter s with caron
- 139 => 8249, # single left-pointing angle quotation mark
- 140 => 338, # latin capital ligature oe
- 142 => 381, # latin capital letter z with caron
- 145 => 8216, # left single quotation mark
- 146 => 8217, # right single quotation mark
- 147 => 8220, # left double quotation mark
- 148 => 8221, # right double quotation mark
- 149 => 8226, # bullet
- 150 => 8211, # en dash
- 151 => 8212, # em dash
- 152 => 732, # small tilde
- 153 => 8482, # trade mark sign
- 154 => 353, # latin small letter s with caron
- 155 => 8250, # single right-pointing angle quotation mark
- 156 => 339, # latin small ligature oe
- 158 => 382, # latin small letter z with caron
- 159 => 376, # latin capital letter y with diaeresis
- }
-
- # See http://www.w3.org/TR/REC-xml/#dt-chardata for details.
- PREDEFINED = {
- 38 => '&amp;', # ampersand
- 60 => '&lt;', # left angle bracket
- 62 => '&gt;', # right angle bracket
- }
-
- # See http://www.w3.org/TR/REC-xml/#charsets for details.
- VALID = [
- 0x9, 0xA, 0xD,
- (0x20..0xD7FF),
- (0xE000..0xFFFD),
- (0x10000..0x10FFFF)
- ]
- end
-
-end
-
-
-######################################################################
-# Enhance the Fixnum class with a XML escaped character conversion.
-#
-class Fixnum
- XChar = Builder::XChar if ! defined?(XChar)
-
- # XML escaped version of chr
- def xchr
- n = XChar::CP1252[self] || self
- case n when *XChar::VALID
- XChar::PREDEFINED[n] or (n<128 ? n.chr : "&##{n};")
- else
- '*'
- end
- end
-end
-
-
-######################################################################
-# Enhance the String class with a XML escaped character version of
-# to_s.
-#
-class String
- # XML escaped version of to_s
- def to_xs
- unpack('U*').map {|n| n.xchr}.join # ASCII, UTF-8
- rescue
- unpack('C*').map {|n| n.xchr}.join # ISO-8859-1, WIN-1252
- end
-end
diff --git a/activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/xmlbase.rb b/activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/xmlbase.rb
deleted file mode 100644
index ace4b56d59..0000000000
--- a/activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/xmlbase.rb
+++ /dev/null
@@ -1,139 +0,0 @@
-#!/usr/bin/env ruby
-
-require 'builder/blankslate'
-
-module Builder
-
- # Generic error for builder
- class IllegalBlockError < RuntimeError; end
-
- # XmlBase is a base class for building XML builders. See
- # Builder::XmlMarkup and Builder::XmlEvents for examples.
- class XmlBase < BlankSlate
-
- # Create an XML markup builder.
- #
- # out:: Object receiving the markup. +out+ must respond to
- # <tt><<</tt>.
- # indent:: Number of spaces used for indentation (0 implies no
- # indentation and no line breaks).
- # initial:: Level of initial indentation.
- #
- def initialize(indent=0, initial=0)
- @indent = indent
- @level = initial
- end
-
- # Create a tag named +sym+. Other than the first argument which
- # is the tag name, the arguments are the same as the tags
- # implemented via <tt>method_missing</tt>.
- def tag!(sym, *args, &block)
- method_missing(sym.to_sym, *args, &block)
- end
-
- # Create XML markup based on the name of the method. This method
- # is never invoked directly, but is called for each markup method
- # in the markup block.
- def method_missing(sym, *args, &block)
- text = nil
- attrs = nil
- sym = "#{sym}:#{args.shift}" if args.first.kind_of?(Symbol)
- args.each do |arg|
- case arg
- when Hash
- attrs ||= {}
- attrs.merge!(arg)
- else
- text ||= ''
- text << arg.to_s
- end
- end
- if block
- unless text.nil?
- raise ArgumentError, "XmlMarkup cannot mix a text argument with a block"
- end
- _indent
- _start_tag(sym, attrs)
- _newline
- _nested_structures(block)
- _indent
- _end_tag(sym)
- _newline
- elsif text.nil?
- _indent
- _start_tag(sym, attrs, true)
- _newline
- else
- _indent
- _start_tag(sym, attrs)
- text! text
- _end_tag(sym)
- _newline
- end
- @target
- end
-
- # Append text to the output target. Escape any markup. May be
- # used within the markup brackets as:
- #
- # builder.p { |b| b.br; b.text! "HI" } #=> <p><br/>HI</p>
- def text!(text)
- _text(_escape(text))
- end
-
- # Append text to the output target without escaping any markup.
- # May be used within the markup brackets as:
- #
- # builder.p { |x| x << "<br/>HI" } #=> <p><br/>HI</p>
- #
- # This is useful when using non-builder enabled software that
- # generates strings. Just insert the string directly into the
- # builder without changing the inserted markup.
- #
- # It is also useful for stacking builder objects. Builders only
- # use <tt><<</tt> to append to the target, so by supporting this
- # method/operation builders can use other builders as their
- # targets.
- def <<(text)
- _text(text)
- end
-
- # For some reason, nil? is sent to the XmlMarkup object. If nil?
- # is not defined and method_missing is invoked, some strange kind
- # of recursion happens. Since nil? won't ever be an XML tag, it
- # is pretty safe to define it here. (Note: this is an example of
- # cargo cult programming,
- # cf. http://fishbowl.pastiche.org/2004/10/13/cargo_cult_programming).
- def nil?
- false
- end
-
- private
-
- require 'builder/xchar'
- def _escape(text)
- text.to_xs
- end
-
- def _escape_quote(text)
- _escape(text).gsub(%r{"}, '&quot;') # " WART
- end
-
- def _newline
- return if @indent == 0
- text! "\n"
- end
-
- def _indent
- return if @indent == 0 || @level == 0
- text!(" " * (@level * @indent))
- end
-
- def _nested_structures(block)
- @level += 1
- block.call(self)
- ensure
- @level -= 1
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/xmlevents.rb b/activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/xmlevents.rb
deleted file mode 100644
index b373e4da3c..0000000000
--- a/activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/xmlevents.rb
+++ /dev/null
@@ -1,63 +0,0 @@
-#!/usr/bin/env ruby
-
-#--
-# Copyright 2004 by Jim Weirich (jim@weirichhouse.org).
-# All rights reserved.
-
-# Permission is granted for use, copying, modification, distribution,
-# and distribution of modified versions of this work as long as the
-# above copyright notice is included.
-#++
-
-require 'builder/xmlmarkup'
-
-module Builder
-
- # Create a series of SAX-like XML events (e.g. start_tag, end_tag)
- # from the markup code. XmlEvent objects are used in a way similar
- # to XmlMarkup objects, except that a series of events are generated
- # and passed to a handler rather than generating character-based
- # markup.
- #
- # Usage:
- # xe = Builder::XmlEvents.new(handler)
- # xe.title("HI") # Sends start_tag/end_tag/text messages to the handler.
- #
- # Indentation may also be selected by providing value for the
- # indentation size and initial indentation level.
- #
- # xe = Builder::XmlEvents.new(handler, indent_size, initial_indent_level)
- #
- # == XML Event Handler
- #
- # The handler object must expect the following events.
- #
- # [<tt>start_tag(tag, attrs)</tt>]
- # Announces that a new tag has been found. +tag+ is the name of
- # the tag and +attrs+ is a hash of attributes for the tag.
- #
- # [<tt>end_tag(tag)</tt>]
- # Announces that an end tag for +tag+ has been found.
- #
- # [<tt>text(text)</tt>]
- # Announces that a string of characters (+text+) has been found.
- # A series of characters may be broken up into more than one
- # +text+ call, so the client cannot assume that a single
- # callback contains all the text data.
- #
- class XmlEvents < XmlMarkup
- def text!(text)
- @target.text(text)
- end
-
- def _start_tag(sym, attrs, end_too=false)
- @target.start_tag(sym, attrs)
- _end_tag(sym) if end_too
- end
-
- def _end_tag(sym)
- @target.end_tag(sym)
- end
- end
-
-end
diff --git a/activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/xmlmarkup.rb b/activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/xmlmarkup.rb
deleted file mode 100644
index ec59dddc36..0000000000
--- a/activesupport/lib/active_support/vendor/builder-2.1.2/lib/builder/xmlmarkup.rb
+++ /dev/null
@@ -1,328 +0,0 @@
-#!/usr/bin/env ruby
-#--
-# Copyright 2004, 2005 by Jim Weirich (jim@weirichhouse.org).
-# All rights reserved.
-
-# Permission is granted for use, copying, modification, distribution,
-# and distribution of modified versions of this work as long as the
-# above copyright notice is included.
-#++
-
-# Provide a flexible and easy to use Builder for creating XML markup.
-# See XmlBuilder for usage details.
-
-require 'builder/xmlbase'
-
-module Builder
-
- # Create XML markup easily. All (well, almost all) methods sent to
- # an XmlMarkup object will be translated to the equivalent XML
- # markup. Any method with a block will be treated as an XML markup
- # tag with nested markup in the block.
- #
- # Examples will demonstrate this easier than words. In the
- # following, +xm+ is an +XmlMarkup+ object.
- #
- # xm.em("emphasized") # => <em>emphasized</em>
- # xm.em { xmm.b("emp & bold") } # => <em><b>emph &amp; bold</b></em>
- # xm.a("A Link", "href"=>"http://onestepback.org")
- # # => <a href="http://onestepback.org">A Link</a>
- # xm.div { br } # => <div><br/></div>
- # xm.target("name"=>"compile", "option"=>"fast")
- # # => <target option="fast" name="compile"\>
- # # NOTE: order of attributes is not specified.
- #
- # xm.instruct! # <?xml version="1.0" encoding="UTF-8"?>
- # xm.html { # <html>
- # xm.head { # <head>
- # xm.title("History") # <title>History</title>
- # } # </head>
- # xm.body { # <body>
- # xm.comment! "HI" # <! -- HI -->
- # xm.h1("Header") # <h1>Header</h1>
- # xm.p("paragraph") # <p>paragraph</p>
- # } # </body>
- # } # </html>
- #
- # == Notes:
- #
- # * The order that attributes are inserted in markup tags is
- # undefined.
- #
- # * Sometimes you wish to insert text without enclosing tags. Use
- # the <tt>text!</tt> method to accomplish this.
- #
- # Example:
- #
- # xm.div { # <div>
- # xm.text! "line"; xm.br # line<br/>
- # xm.text! "another line"; xmbr # another line<br/>
- # } # </div>
- #
- # * The special XML characters <, >, and & are converted to &lt;,
- # &gt; and &amp; automatically. Use the <tt><<</tt> operation to
- # insert text without modification.
- #
- # * Sometimes tags use special characters not allowed in ruby
- # identifiers. Use the <tt>tag!</tt> method to handle these
- # cases.
- #
- # Example:
- #
- # xml.tag!("SOAP:Envelope") { ... }
- #
- # will produce ...
- #
- # <SOAP:Envelope> ... </SOAP:Envelope>"
- #
- # <tt>tag!</tt> will also take text and attribute arguments (after
- # the tag name) like normal markup methods. (But see the next
- # bullet item for a better way to handle XML namespaces).
- #
- # * Direct support for XML namespaces is now available. If the
- # first argument to a tag call is a symbol, it will be joined to
- # the tag to produce a namespace:tag combination. It is easier to
- # show this than describe it.
- #
- # xml.SOAP :Envelope do ... end
- #
- # Just put a space before the colon in a namespace to produce the
- # right form for builder (e.g. "<tt>SOAP:Envelope</tt>" =>
- # "<tt>xml.SOAP :Envelope</tt>")
- #
- # * XmlMarkup builds the markup in any object (called a _target_)
- # that accepts the <tt><<</tt> method. If no target is given,
- # then XmlMarkup defaults to a string target.
- #
- # Examples:
- #
- # xm = Builder::XmlMarkup.new
- # result = xm.title("yada")
- # # result is a string containing the markup.
- #
- # buffer = ""
- # xm = Builder::XmlMarkup.new(buffer)
- # # The markup is appended to buffer (using <<)
- #
- # xm = Builder::XmlMarkup.new(STDOUT)
- # # The markup is written to STDOUT (using <<)
- #
- # xm = Builder::XmlMarkup.new
- # x2 = Builder::XmlMarkup.new(:target=>xm)
- # # Markup written to +x2+ will be send to +xm+.
- #
- # * Indentation is enabled by providing the number of spaces to
- # indent for each level as a second argument to XmlBuilder.new.
- # Initial indentation may be specified using a third parameter.
- #
- # Example:
- #
- # xm = Builder.new(:indent=>2)
- # # xm will produce nicely formatted and indented XML.
- #
- # xm = Builder.new(:indent=>2, :margin=>4)
- # # xm will produce nicely formatted and indented XML with 2
- # # spaces per indent and an over all indentation level of 4.
- #
- # builder = Builder::XmlMarkup.new(:target=>$stdout, :indent=>2)
- # builder.name { |b| b.first("Jim"); b.last("Weirich) }
- # # prints:
- # # <name>
- # # <first>Jim</first>
- # # <last>Weirich</last>
- # # </name>
- #
- # * The instance_eval implementation which forces self to refer to
- # the message receiver as self is now obsolete. We now use normal
- # block calls to execute the markup block. This means that all
- # markup methods must now be explicitly send to the xml builder.
- # For instance, instead of
- #
- # xml.div { strong("text") }
- #
- # you need to write:
- #
- # xml.div { xml.strong("text") }
- #
- # Although more verbose, the subtle change in semantics within the
- # block was found to be prone to error. To make this change a
- # little less cumbersome, the markup block now gets the markup
- # object sent as an argument, allowing you to use a shorter alias
- # within the block.
- #
- # For example:
- #
- # xml_builder = Builder::XmlMarkup.new
- # xml_builder.div { |xml|
- # xml.stong("text")
- # }
- #
- class XmlMarkup < XmlBase
-
- # Create an XML markup builder. Parameters are specified by an
- # option hash.
- #
- # :target=><em>target_object</em>::
- # Object receiving the markup. +out+ must respond to the
- # <tt><<</tt> operator. The default is a plain string target.
- #
- # :indent=><em>indentation</em>::
- # Number of spaces used for indentation. The default is no
- # indentation and no line breaks.
- #
- # :margin=><em>initial_indentation_level</em>::
- # Amount of initial indentation (specified in levels, not
- # spaces).
- #
- # :escape_attrs=><b>OBSOLETE</em>::
- # The :escape_attrs option is no longer supported by builder
- # (and will be quietly ignored). String attribute values are
- # now automatically escaped. If you need unescaped attribute
- # values (perhaps you are using entities in the attribute
- # values), then give the value as a Symbol. This allows much
- # finer control over escaping attribute values.
- #
- def initialize(options={})
- indent = options[:indent] || 0
- margin = options[:margin] || 0
- super(indent, margin)
- @target = options[:target] || ""
- end
-
- # Return the target of the builder.
- def target!
- @target
- end
-
- def comment!(comment_text)
- _ensure_no_block block_given?
- _special("<!-- ", " -->", comment_text, nil)
- end
-
- # Insert an XML declaration into the XML markup.
- #
- # For example:
- #
- # xml.declare! :ELEMENT, :blah, "yada"
- # # => <!ELEMENT blah "yada">
- def declare!(inst, *args, &block)
- _indent
- @target << "<!#{inst}"
- args.each do |arg|
- case arg
- when String
- @target << %{ "#{arg}"} # " WART
- when Symbol
- @target << " #{arg}"
- end
- end
- if block_given?
- @target << " ["
- _newline
- _nested_structures(block)
- @target << "]"
- end
- @target << ">"
- _newline
- end
-
- # Insert a processing instruction into the XML markup. E.g.
- #
- # For example:
- #
- # xml.instruct!
- # #=> <?xml version="1.0" encoding="UTF-8"?>
- # xml.instruct! :aaa, :bbb=>"ccc"
- # #=> <?aaa bbb="ccc"?>
- #
- def instruct!(directive_tag=:xml, attrs={})
- _ensure_no_block block_given?
- if directive_tag == :xml
- a = { :version=>"1.0", :encoding=>"UTF-8" }
- attrs = a.merge attrs
- end
- _special(
- "<?#{directive_tag}",
- "?>",
- nil,
- attrs,
- [:version, :encoding, :standalone])
- end
-
- # Insert a CDATA section into the XML markup.
- #
- # For example:
- #
- # xml.cdata!("text to be included in cdata")
- # #=> <![CDATA[text to be included in cdata]]>
- #
- def cdata!(text)
- _ensure_no_block block_given?
- _special("<![CDATA[", "]]>", text, nil)
- end
-
- private
-
- # NOTE: All private methods of a builder object are prefixed when
- # a "_" character to avoid possible conflict with XML tag names.
-
- # Insert text directly in to the builder's target.
- def _text(text)
- @target << text
- end
-
- # Insert special instruction.
- def _special(open, close, data=nil, attrs=nil, order=[])
- _indent
- @target << open
- @target << data if data
- _insert_attributes(attrs, order) if attrs
- @target << close
- _newline
- end
-
- # Start an XML tag. If <tt>end_too</tt> is true, then the start
- # tag is also the end tag (e.g. <br/>
- def _start_tag(sym, attrs, end_too=false)
- @target << "<#{sym}"
- _insert_attributes(attrs)
- @target << "/" if end_too
- @target << ">"
- end
-
- # Insert an ending tag.
- def _end_tag(sym)
- @target << "</#{sym}>"
- end
-
- # Insert the attributes (given in the hash).
- def _insert_attributes(attrs, order=[])
- return if attrs.nil?
- order.each do |k|
- v = attrs[k]
- @target << %{ #{k}="#{_attr_value(v)}"} if v # " WART
- end
- attrs.each do |k, v|
- @target << %{ #{k}="#{_attr_value(v)}"} unless order.member?(k) # " WART
- end
- end
-
- def _attr_value(value)
- case value
- when Symbol
- value.to_s
- else
- _escape_quote(value.to_s)
- end
- end
-
- def _ensure_no_block(got_block)
- if got_block
- fail IllegalBlockError,
- "Blocks are not allowed on XML instructions"
- end
- end
-
- end
-
-end
diff --git a/activesupport/lib/active_support/vendor/memcache-client-1.7.5/lib/memcache.rb b/activesupport/lib/active_support/vendor/memcache-client-1.7.5/lib/memcache.rb
deleted file mode 100644
index 3fcc388ba0..0000000000
--- a/activesupport/lib/active_support/vendor/memcache-client-1.7.5/lib/memcache.rb
+++ /dev/null
@@ -1,1133 +0,0 @@
-$TESTING = defined?($TESTING) && $TESTING
-
-require 'socket'
-require 'thread'
-require 'zlib'
-require 'digest/sha1'
-require 'net/protocol'
-
-##
-# A Ruby client library for memcached.
-#
-
-class MemCache
-
- ##
- # The version of MemCache you are using.
-
- VERSION = '1.7.5'
-
- ##
- # Default options for the cache object.
-
- DEFAULT_OPTIONS = {
- :namespace => nil,
- :readonly => false,
- :multithread => true,
- :failover => true,
- :timeout => 0.5,
- :logger => nil,
- :no_reply => false,
- :check_size => true,
- :autofix_keys => false,
- :namespace_separator => ':',
- }
-
- ##
- # Default memcached port.
-
- DEFAULT_PORT = 11211
-
- ##
- # Default memcached server weight.
-
- DEFAULT_WEIGHT = 1
-
- ##
- # The namespace for this instance
-
- attr_reader :namespace
-
- ##
- # The multithread setting for this instance
-
- attr_reader :multithread
-
- ##
- # Whether to try to fix keys that are too long and will be truncated by
- # using their SHA1 hash instead.
- # The hash is only used on keys longer than 250 characters, or containing spaces,
- # to avoid impacting performance unnecesarily.
- #
- # In theory, your code should generate correct keys when calling memcache,
- # so it's your responsibility and you should try to fix this problem at its source.
- #
- # But if that's not possible, enable this option and memcache-client will give you a hand.
-
- attr_reader :autofix_keys
-
- ##
- # The servers this client talks to. Play at your own peril.
-
- attr_reader :servers
-
- ##
- # Socket timeout limit with this client, defaults to 0.5 sec.
- # Set to nil to disable timeouts.
-
- attr_reader :timeout
-
- ##
- # Should the client try to failover to another server if the
- # first server is down? Defaults to true.
-
- attr_reader :failover
-
- ##
- # Log debug/info/warn/error to the given Logger, defaults to nil.
-
- attr_reader :logger
-
- ##
- # Don't send or look for a reply from the memcached server for write operations.
- # Please note this feature only works in memcached 1.2.5 and later. Earlier
- # versions will reply with "ERROR".
- attr_reader :no_reply
-
- ##
- # Accepts a list of +servers+ and a list of +opts+. +servers+ may be
- # omitted. See +servers=+ for acceptable server list arguments.
- #
- # Valid options for +opts+ are:
- #
- # [:namespace] Prepends this value to all keys added or retrieved.
- # [:readonly] Raises an exception on cache writes when true.
- # [:multithread] Wraps cache access in a Mutex for thread safety. Defaults to true.
- # [:failover] Should the client try to failover to another server if the
- # first server is down? Defaults to true.
- # [:timeout] Time to use as the socket read timeout. Defaults to 0.5 sec,
- # set to nil to disable timeouts.
- # [:logger] Logger to use for info/debug output, defaults to nil
- # [:no_reply] Don't bother looking for a reply for write operations (i.e. they
- # become 'fire and forget'), memcached 1.2.5 and later only, speeds up
- # set/add/delete/incr/decr significantly.
- # [:check_size] Raises a MemCacheError if the value to be set is greater than 1 MB, which
- # is the maximum key size for the standard memcached server. Defaults to true.
- # [:autofix_keys] If a key is longer than 250 characters or contains spaces,
- # use an SHA1 hash instead, to prevent collisions on truncated keys.
- # Other options are ignored.
-
- def initialize(*args)
- servers = []
- opts = {}
-
- case args.length
- when 0 then # NOP
- when 1 then
- arg = args.shift
- case arg
- when Hash then opts = arg
- when Array then servers = arg
- when String then servers = [arg]
- else raise ArgumentError, 'first argument must be Array, Hash or String'
- end
- when 2 then
- servers, opts = args
- else
- raise ArgumentError, "wrong number of arguments (#{args.length} for 2)"
- end
-
- opts = DEFAULT_OPTIONS.merge opts
- @namespace = opts[:namespace]
- @readonly = opts[:readonly]
- @multithread = opts[:multithread]
- @autofix_keys = opts[:autofix_keys]
- @timeout = opts[:timeout]
- @failover = opts[:failover]
- @logger = opts[:logger]
- @no_reply = opts[:no_reply]
- @check_size = opts[:check_size]
- @namespace_separator = opts[:namespace_separator]
- @mutex = Mutex.new if @multithread
-
- logger.info { "memcache-client #{VERSION} #{Array(servers).inspect}" } if logger
-
- Thread.current[:memcache_client] = self.object_id if !@multithread
-
- self.servers = servers
- end
-
- ##
- # Returns a string representation of the cache object.
-
- def inspect
- "<MemCache: %d servers, ns: %p, ro: %p>" %
- [@servers.length, @namespace, @readonly]
- end
-
- ##
- # Returns whether there is at least one active server for the object.
-
- def active?
- not @servers.empty?
- end
-
- ##
- # Returns whether or not the cache object was created read only.
-
- def readonly?
- @readonly
- end
-
- ##
- # Set the servers that the requests will be distributed between. Entries
- # can be either strings of the form "hostname:port" or
- # "hostname:port:weight" or MemCache::Server objects.
- #
- def servers=(servers)
- # Create the server objects.
- @servers = Array(servers).collect do |server|
- case server
- when String
- host, port, weight = server.split ':', 3
- port ||= DEFAULT_PORT
- weight ||= DEFAULT_WEIGHT
- Server.new self, host, port, weight
- else
- server
- end
- end
-
- logger.debug { "Servers now: #{@servers.inspect}" } if logger
-
- # There's no point in doing this if there's only one server
- @continuum = create_continuum_for(@servers) if @servers.size > 1
-
- @servers
- end
-
- ##
- # Decrements the value for +key+ by +amount+ and returns the new value.
- # +key+ must already exist. If +key+ is not an integer, it is assumed to be
- # 0. +key+ can not be decremented below 0.
-
- def decr(key, amount = 1)
- raise MemCacheError, "Update of readonly cache" if @readonly
- with_server(key) do |server, cache_key|
- cache_decr server, cache_key, amount
- end
- rescue TypeError => err
- handle_error nil, err
- end
-
- ##
- # Retrieves +key+ from memcache. If +raw+ is false, the value will be
- # unmarshalled.
-
- def get(key, raw = false)
- with_server(key) do |server, cache_key|
- logger.debug { "get #{key} from #{server.inspect}" } if logger
- value = cache_get server, cache_key
- return nil if value.nil?
- value = Marshal.load value unless raw
- return value
- end
- rescue TypeError => err
- handle_error nil, err
- end
-
- ##
- # Performs a +get+ with the given +key+. If
- # the value does not exist and a block was given,
- # the block will be called and the result saved via +add+.
- #
- # If you do not provide a block, using this
- # method is the same as using +get+.
- #
- def fetch(key, expiry = 0, raw = false)
- value = get(key, raw)
-
- if value.nil? && block_given?
- value = yield
- add(key, value, expiry, raw)
- end
-
- value
- end
-
- ##
- # Retrieves multiple values from memcached in parallel, if possible.
- #
- # The memcached protocol supports the ability to retrieve multiple
- # keys in a single request. Pass in an array of keys to this method
- # and it will:
- #
- # 1. map the key to the appropriate memcached server
- # 2. send a single request to each server that has one or more key values
- #
- # Returns a hash of values.
- #
- # cache["a"] = 1
- # cache["b"] = 2
- # cache.get_multi "a", "b" # => { "a" => 1, "b" => 2 }
- #
- # Note that get_multi assumes the values are marshalled.
-
- def get_multi(*keys)
- raise MemCacheError, 'No active servers' unless active?
-
- keys.flatten!
- key_count = keys.length
- cache_keys = {}
- server_keys = Hash.new { |h,k| h[k] = [] }
-
- # map keys to servers
- keys.each do |key|
- server, cache_key = request_setup key
- cache_keys[cache_key] = key
- server_keys[server] << cache_key
- end
-
- results = {}
-
- server_keys.each do |server, keys_for_server|
- keys_for_server_str = keys_for_server.join ' '
- begin
- values = cache_get_multi server, keys_for_server_str
- values.each do |key, value|
- results[cache_keys[key]] = Marshal.load value
- end
- rescue IndexError => e
- # Ignore this server and try the others
- logger.warn { "Unable to retrieve #{keys_for_server.size} elements from #{server.inspect}: #{e.message}"} if logger
- end
- end
-
- return results
- rescue TypeError => err
- handle_error nil, err
- end
-
- ##
- # Increments the value for +key+ by +amount+ and returns the new value.
- # +key+ must already exist. If +key+ is not an integer, it is assumed to be
- # 0.
-
- def incr(key, amount = 1)
- raise MemCacheError, "Update of readonly cache" if @readonly
- with_server(key) do |server, cache_key|
- cache_incr server, cache_key, amount
- end
- rescue TypeError => err
- handle_error nil, err
- end
-
- ##
- # Add +key+ to the cache with value +value+ that expires in +expiry+
- # seconds. If +raw+ is true, +value+ will not be Marshalled.
- #
- # Warning: Readers should not call this method in the event of a cache miss;
- # see MemCache#add.
-
- ONE_MB = 1024 * 1024
-
- def set(key, value, expiry = 0, raw = false)
- raise MemCacheError, "Update of readonly cache" if @readonly
-
- value = Marshal.dump value unless raw
- with_server(key) do |server, cache_key|
- logger.debug { "set #{key} to #{server.inspect}: #{value.to_s.size}" } if logger
-
- if @check_size && value.to_s.size > ONE_MB
- raise MemCacheError, "Value too large, memcached can only store 1MB of data per key"
- end
-
- command = "set #{cache_key} 0 #{expiry} #{value.to_s.size}#{noreply}\r\n#{value}\r\n"
-
- with_socket_management(server) do |socket|
- socket.write command
- break nil if @no_reply
- result = socket.gets
- raise_on_error_response! result
-
- if result.nil?
- server.close
- raise MemCacheError, "lost connection to #{server.host}:#{server.port}"
- end
-
- result
- end
- end
- end
-
- ##
- # "cas" is a check and set operation which means "store this data but
- # only if no one else has updated since I last fetched it." This can
- # be used as a form of optimistic locking.
- #
- # Works in block form like so:
- # cache.cas('some-key') do |value|
- # value + 1
- # end
- #
- # Returns:
- # +nil+ if the value was not found on the memcached server.
- # +STORED+ if the value was updated successfully
- # +EXISTS+ if the value was updated by someone else since last fetch
-
- def cas(key, expiry=0, raw=false)
- raise MemCacheError, "Update of readonly cache" if @readonly
- raise MemCacheError, "A block is required" unless block_given?
-
- (value, token) = gets(key, raw)
- return nil unless value
- updated = yield value
- value = Marshal.dump updated unless raw
-
- with_server(key) do |server, cache_key|
- logger.debug { "cas #{key} to #{server.inspect}: #{value.to_s.size}" } if logger
- command = "cas #{cache_key} 0 #{expiry} #{value.to_s.size} #{token}#{noreply}\r\n#{value}\r\n"
-
- with_socket_management(server) do |socket|
- socket.write command
- break nil if @no_reply
- result = socket.gets
- raise_on_error_response! result
-
- if result.nil?
- server.close
- raise MemCacheError, "lost connection to #{server.host}:#{server.port}"
- end
-
- result
- end
- end
- end
-
- ##
- # Add +key+ to the cache with value +value+ that expires in +expiry+
- # seconds, but only if +key+ does not already exist in the cache.
- # If +raw+ is true, +value+ will not be Marshalled.
- #
- # Readers should call this method in the event of a cache miss, not
- # MemCache#set.
-
- def add(key, value, expiry = 0, raw = false)
- raise MemCacheError, "Update of readonly cache" if @readonly
- value = Marshal.dump value unless raw
- with_server(key) do |server, cache_key|
- logger.debug { "add #{key} to #{server}: #{value ? value.to_s.size : 'nil'}" } if logger
- command = "add #{cache_key} 0 #{expiry} #{value.to_s.size}#{noreply}\r\n#{value}\r\n"
-
- with_socket_management(server) do |socket|
- socket.write command
- break nil if @no_reply
- result = socket.gets
- raise_on_error_response! result
- result
- end
- end
- end
-
- ##
- # Add +key+ to the cache with value +value+ that expires in +expiry+
- # seconds, but only if +key+ already exists in the cache.
- # If +raw+ is true, +value+ will not be Marshalled.
- def replace(key, value, expiry = 0, raw = false)
- raise MemCacheError, "Update of readonly cache" if @readonly
- value = Marshal.dump value unless raw
- with_server(key) do |server, cache_key|
- logger.debug { "replace #{key} to #{server}: #{value ? value.to_s.size : 'nil'}" } if logger
- command = "replace #{cache_key} 0 #{expiry} #{value.to_s.size}#{noreply}\r\n#{value}\r\n"
-
- with_socket_management(server) do |socket|
- socket.write command
- break nil if @no_reply
- result = socket.gets
- raise_on_error_response! result
- result
- end
- end
- end
-
- ##
- # Append - 'add this data to an existing key after existing data'
- # Please note the value is always passed to memcached as raw since it
- # doesn't make a lot of sense to concatenate marshalled data together.
- def append(key, value)
- raise MemCacheError, "Update of readonly cache" if @readonly
- with_server(key) do |server, cache_key|
- logger.debug { "append #{key} to #{server}: #{value ? value.to_s.size : 'nil'}" } if logger
- command = "append #{cache_key} 0 0 #{value.to_s.size}#{noreply}\r\n#{value}\r\n"
-
- with_socket_management(server) do |socket|
- socket.write command
- break nil if @no_reply
- result = socket.gets
- raise_on_error_response! result
- result
- end
- end
- end
-
- ##
- # Prepend - 'add this data to an existing key before existing data'
- # Please note the value is always passed to memcached as raw since it
- # doesn't make a lot of sense to concatenate marshalled data together.
- def prepend(key, value)
- raise MemCacheError, "Update of readonly cache" if @readonly
- with_server(key) do |server, cache_key|
- logger.debug { "prepend #{key} to #{server}: #{value ? value.to_s.size : 'nil'}" } if logger
- command = "prepend #{cache_key} 0 0 #{value.to_s.size}#{noreply}\r\n#{value}\r\n"
-
- with_socket_management(server) do |socket|
- socket.write command
- break nil if @no_reply
- result = socket.gets
- raise_on_error_response! result
- result
- end
- end
- end
-
- ##
- # Removes +key+ from the cache in +expiry+ seconds.
-
- def delete(key, expiry = 0)
- raise MemCacheError, "Update of readonly cache" if @readonly
- with_server(key) do |server, cache_key|
- with_socket_management(server) do |socket|
- logger.debug { "delete #{cache_key} on #{server}" } if logger
- socket.write "delete #{cache_key} #{expiry}#{noreply}\r\n"
- break nil if @no_reply
- result = socket.gets
- raise_on_error_response! result
- result
- end
- end
- end
-
- ##
- # Flush the cache from all memcache servers.
- # A non-zero value for +delay+ will ensure that the flush
- # is propogated slowly through your memcached server farm.
- # The Nth server will be flushed N*delay seconds from now,
- # asynchronously so this method returns quickly.
- # This prevents a huge database spike due to a total
- # flush all at once.
-
- def flush_all(delay=0)
- raise MemCacheError, 'No active servers' unless active?
- raise MemCacheError, "Update of readonly cache" if @readonly
-
- begin
- delay_time = 0
- @servers.each do |server|
- with_socket_management(server) do |socket|
- logger.debug { "flush_all #{delay_time} on #{server}" } if logger
- if delay == 0 # older versions of memcached will fail silently otherwise
- socket.write "flush_all#{noreply}\r\n"
- else
- socket.write "flush_all #{delay_time}#{noreply}\r\n"
- end
- break nil if @no_reply
- result = socket.gets
- raise_on_error_response! result
- result
- end
- delay_time += delay
- end
- rescue IndexError => err
- handle_error nil, err
- end
- end
-
- ##
- # Reset the connection to all memcache servers. This should be called if
- # there is a problem with a cache lookup that might have left the connection
- # in a corrupted state.
-
- def reset
- @servers.each { |server| server.close }
- end
-
- ##
- # Returns statistics for each memcached server. An explanation of the
- # statistics can be found in the memcached docs:
- #
- # http://code.sixapart.com/svn/memcached/trunk/server/doc/protocol.txt
- #
- # Example:
- #
- # >> pp CACHE.stats
- # {"localhost:11211"=>
- # {"bytes"=>4718,
- # "pid"=>20188,
- # "connection_structures"=>4,
- # "time"=>1162278121,
- # "pointer_size"=>32,
- # "limit_maxbytes"=>67108864,
- # "cmd_get"=>14532,
- # "version"=>"1.2.0",
- # "bytes_written"=>432583,
- # "cmd_set"=>32,
- # "get_misses"=>0,
- # "total_connections"=>19,
- # "curr_connections"=>3,
- # "curr_items"=>4,
- # "uptime"=>1557,
- # "get_hits"=>14532,
- # "total_items"=>32,
- # "rusage_system"=>0.313952,
- # "rusage_user"=>0.119981,
- # "bytes_read"=>190619}}
- # => nil
-
- def stats
- raise MemCacheError, "No active servers" unless active?
- server_stats = {}
-
- @servers.each do |server|
- next unless server.alive?
-
- with_socket_management(server) do |socket|
- value = nil
- socket.write "stats\r\n"
- stats = {}
- while line = socket.gets do
- raise_on_error_response! line
- break if line == "END\r\n"
- if line =~ /\ASTAT ([\S]+) ([\w\.\:]+)/ then
- name, value = $1, $2
- stats[name] = case name
- when 'version'
- value
- when 'rusage_user', 'rusage_system' then
- seconds, microseconds = value.split(/:/, 2)
- microseconds ||= 0
- Float(seconds) + (Float(microseconds) / 1_000_000)
- else
- if value =~ /\A\d+\Z/ then
- value.to_i
- else
- value
- end
- end
- end
- end
- server_stats["#{server.host}:#{server.port}"] = stats
- end
- end
-
- raise MemCacheError, "No active servers" if server_stats.empty?
- server_stats
- end
-
- ##
- # Shortcut to get a value from the cache.
-
- alias [] get
-
- ##
- # Shortcut to save a value in the cache. This method does not set an
- # expiration on the entry. Use set to specify an explicit expiry.
-
- def []=(key, value)
- set key, value
- end
-
- protected unless $TESTING
-
- ##
- # Create a key for the cache, incorporating the namespace qualifier if
- # requested.
-
- def make_cache_key(key)
- if @autofix_keys and (key =~ /\s/ or (key.length + (namespace.nil? ? 0 : namespace.length)) > 250)
- key = "#{Digest::SHA1.hexdigest(key)}-autofixed"
- end
-
- if namespace.nil? then
- key
- else
- "#{@namespace}#{@namespace_separator}#{key}"
- end
- end
-
- ##
- # Returns an interoperable hash value for +key+. (I think, docs are
- # sketchy for down servers).
-
- def hash_for(key)
- Zlib.crc32(key)
- end
-
- ##
- # Pick a server to handle the request based on a hash of the key.
-
- def get_server_for_key(key, options = {})
- raise ArgumentError, "illegal character in key #{key.inspect}" if
- key =~ /\s/
- raise ArgumentError, "key too long #{key.inspect}" if key.length > 250
- raise MemCacheError, "No servers available" if @servers.empty?
- return @servers.first if @servers.length == 1
-
- hkey = hash_for(key)
-
- 20.times do |try|
- entryidx = Continuum.binary_search(@continuum, hkey)
- server = @continuum[entryidx].server
- return server if server.alive?
- break unless failover
- hkey = hash_for "#{try}#{key}"
- end
-
- raise MemCacheError, "No servers available"
- end
-
- ##
- # Performs a raw decr for +cache_key+ from +server+. Returns nil if not
- # found.
-
- def cache_decr(server, cache_key, amount)
- with_socket_management(server) do |socket|
- socket.write "decr #{cache_key} #{amount}#{noreply}\r\n"
- break nil if @no_reply
- text = socket.gets
- raise_on_error_response! text
- return nil if text == "NOT_FOUND\r\n"
- return text.to_i
- end
- end
-
- ##
- # Fetches the raw data for +cache_key+ from +server+. Returns nil on cache
- # miss.
-
- def cache_get(server, cache_key)
- with_socket_management(server) do |socket|
- socket.write "get #{cache_key}\r\n"
- keyline = socket.gets # "VALUE <key> <flags> <bytes>\r\n"
-
- if keyline.nil? then
- server.close
- raise MemCacheError, "lost connection to #{server.host}:#{server.port}"
- end
-
- raise_on_error_response! keyline
- return nil if keyline == "END\r\n"
-
- unless keyline =~ /(\d+)\r/ then
- server.close
- raise MemCacheError, "unexpected response #{keyline.inspect}"
- end
- value = socket.read $1.to_i
- socket.read 2 # "\r\n"
- socket.gets # "END\r\n"
- return value
- end
- end
-
- def gets(key, raw = false)
- with_server(key) do |server, cache_key|
- logger.debug { "gets #{key} from #{server.inspect}" } if logger
- result = with_socket_management(server) do |socket|
- socket.write "gets #{cache_key}\r\n"
- keyline = socket.gets # "VALUE <key> <flags> <bytes> <cas token>\r\n"
-
- if keyline.nil? then
- server.close
- raise MemCacheError, "lost connection to #{server.host}:#{server.port}"
- end
-
- raise_on_error_response! keyline
- return nil if keyline == "END\r\n"
-
- unless keyline =~ /(\d+) (\w+)\r/ then
- server.close
- raise MemCacheError, "unexpected response #{keyline.inspect}"
- end
- value = socket.read $1.to_i
- socket.read 2 # "\r\n"
- socket.gets # "END\r\n"
- [value, $2]
- end
- result[0] = Marshal.load result[0] unless raw
- result
- end
- rescue TypeError => err
- handle_error nil, err
- end
-
-
- ##
- # Fetches +cache_keys+ from +server+ using a multi-get.
-
- def cache_get_multi(server, cache_keys)
- with_socket_management(server) do |socket|
- values = {}
- socket.write "get #{cache_keys}\r\n"
-
- while keyline = socket.gets do
- return values if keyline == "END\r\n"
- raise_on_error_response! keyline
-
- unless keyline =~ /\AVALUE (.+) (.+) (.+)/ then
- server.close
- raise MemCacheError, "unexpected response #{keyline.inspect}"
- end
-
- key, data_length = $1, $3
- values[$1] = socket.read data_length.to_i
- socket.read(2) # "\r\n"
- end
-
- server.close
- raise MemCacheError, "lost connection to #{server.host}:#{server.port}" # TODO: retry here too
- end
- end
-
- ##
- # Performs a raw incr for +cache_key+ from +server+. Returns nil if not
- # found.
-
- def cache_incr(server, cache_key, amount)
- with_socket_management(server) do |socket|
- socket.write "incr #{cache_key} #{amount}#{noreply}\r\n"
- break nil if @no_reply
- text = socket.gets
- raise_on_error_response! text
- return nil if text == "NOT_FOUND\r\n"
- return text.to_i
- end
- end
-
- ##
- # Gets or creates a socket connected to the given server, and yields it
- # to the block, wrapped in a mutex synchronization if @multithread is true.
- #
- # If a socket error (SocketError, SystemCallError, IOError) or protocol error
- # (MemCacheError) is raised by the block, closes the socket, attempts to
- # connect again, and retries the block (once). If an error is again raised,
- # reraises it as MemCacheError.
- #
- # If unable to connect to the server (or if in the reconnect wait period),
- # raises MemCacheError. Note that the socket connect code marks a server
- # dead for a timeout period, so retrying does not apply to connection attempt
- # failures (but does still apply to unexpectedly lost connections etc.).
-
- def with_socket_management(server, &block)
- check_multithread_status!
-
- @mutex.lock if @multithread
- retried = false
-
- begin
- socket = server.socket
-
- # Raise an IndexError to show this server is out of whack. If were inside
- # a with_server block, we'll catch it and attempt to restart the operation.
-
- raise IndexError, "No connection to server (#{server.status})" if socket.nil?
-
- block.call(socket)
-
- rescue SocketError, Errno::EAGAIN, Timeout::Error => err
- logger.warn { "Socket failure: #{err.message}" } if logger
- server.mark_dead(err)
- handle_error(server, err)
-
- rescue MemCacheError, SystemCallError, IOError => err
- logger.warn { "Generic failure: #{err.class.name}: #{err.message}" } if logger
- handle_error(server, err) if retried || socket.nil?
- retried = true
- retry
- end
- ensure
- @mutex.unlock if @multithread
- end
-
- def with_server(key)
- retried = false
- begin
- server, cache_key = request_setup(key)
- yield server, cache_key
- rescue IndexError => e
- logger.warn { "Server failed: #{e.class.name}: #{e.message}" } if logger
- if !retried && @servers.size > 1
- logger.info { "Connection to server #{server.inspect} DIED! Retrying operation..." } if logger
- retried = true
- retry
- end
- handle_error(nil, e)
- end
- end
-
- ##
- # Handles +error+ from +server+.
-
- def handle_error(server, error)
- raise error if error.is_a?(MemCacheError)
- server.close if server
- new_error = MemCacheError.new error.message
- new_error.set_backtrace error.backtrace
- raise new_error
- end
-
- def noreply
- @no_reply ? ' noreply' : ''
- end
-
- ##
- # Performs setup for making a request with +key+ from memcached. Returns
- # the server to fetch the key from and the complete key to use.
-
- def request_setup(key)
- raise MemCacheError, 'No active servers' unless active?
- cache_key = make_cache_key key
- server = get_server_for_key cache_key
- return server, cache_key
- end
-
- def raise_on_error_response!(response)
- if response =~ /\A(?:CLIENT_|SERVER_)?ERROR(.*)/
- raise MemCacheError, $1.strip
- end
- end
-
- def create_continuum_for(servers)
- total_weight = servers.inject(0) { |memo, srv| memo + srv.weight }
- continuum = []
-
- servers.each do |server|
- entry_count_for(server, servers.size, total_weight).times do |idx|
- hash = Digest::SHA1.hexdigest("#{server.host}:#{server.port}:#{idx}")
- value = Integer("0x#{hash[0..7]}")
- continuum << Continuum::Entry.new(value, server)
- end
- end
-
- continuum.sort { |a, b| a.value <=> b.value }
- end
-
- def entry_count_for(server, total_servers, total_weight)
- ((total_servers * Continuum::POINTS_PER_SERVER * server.weight) / Float(total_weight)).floor
- end
-
- def check_multithread_status!
- return if @multithread
-
- if Thread.current[:memcache_client] != self.object_id
- raise MemCacheError, <<-EOM
- You are accessing this memcache-client instance from multiple threads but have not enabled multithread support.
- Normally: MemCache.new(['localhost:11211'], :multithread => true)
- In Rails: config.cache_store = [:mem_cache_store, 'localhost:11211', { :multithread => true }]
- EOM
- end
- end
-
- ##
- # This class represents a memcached server instance.
-
- class Server
-
- ##
- # The amount of time to wait before attempting to re-establish a
- # connection with a server that is marked dead.
-
- RETRY_DELAY = 30.0
-
- ##
- # The host the memcached server is running on.
-
- attr_reader :host
-
- ##
- # The port the memcached server is listening on.
-
- attr_reader :port
-
- ##
- # The weight given to the server.
-
- attr_reader :weight
-
- ##
- # The time of next retry if the connection is dead.
-
- attr_reader :retry
-
- ##
- # A text status string describing the state of the server.
-
- attr_reader :status
-
- attr_reader :logger
-
- ##
- # Create a new MemCache::Server object for the memcached instance
- # listening on the given host and port, weighted by the given weight.
-
- def initialize(memcache, host, port = DEFAULT_PORT, weight = DEFAULT_WEIGHT)
- raise ArgumentError, "No host specified" if host.nil? or host.empty?
- raise ArgumentError, "No port specified" if port.nil? or port.to_i.zero?
-
- @host = host
- @port = port.to_i
- @weight = weight.to_i
-
- @sock = nil
- @retry = nil
- @status = 'NOT CONNECTED'
- @timeout = memcache.timeout
- @logger = memcache.logger
- end
-
- ##
- # Return a string representation of the server object.
-
- def inspect
- "<MemCache::Server: %s:%d [%d] (%s)>" % [@host, @port, @weight, @status]
- end
-
- ##
- # Check whether the server connection is alive. This will cause the
- # socket to attempt to connect if it isn't already connected and or if
- # the server was previously marked as down and the retry time has
- # been exceeded.
-
- def alive?
- !!socket
- end
-
- ##
- # Try to connect to the memcached server targeted by this object.
- # Returns the connected socket object on success or nil on failure.
-
- def socket
- return @sock if @sock and not @sock.closed?
-
- @sock = nil
-
- # If the host was dead, don't retry for a while.
- return if @retry and @retry > Time.now
-
- # Attempt to connect if not already connected.
- begin
- @sock = connect_to(@host, @port, @timeout)
- @sock.setsockopt Socket::IPPROTO_TCP, Socket::TCP_NODELAY, 1
- @retry = nil
- @status = 'CONNECTED'
- rescue SocketError, SystemCallError, IOError => err
- logger.warn { "Unable to open socket: #{err.class.name}, #{err.message}" } if logger
- mark_dead err
- end
-
- return @sock
- end
-
- def connect_to(host, port, timeout=nil)
- io = MemCache::BufferedIO.new(TCPSocket.new(host, port))
- io.read_timeout = timeout
- io
- end
-
- ##
- # Close the connection to the memcached server targeted by this
- # object. The server is not considered dead.
-
- def close
- @sock.close if @sock && !@sock.closed?
- @sock = nil
- @retry = nil
- @status = "NOT CONNECTED"
- end
-
- ##
- # Mark the server as dead and close its socket.
-
- def mark_dead(error)
- @sock.close if @sock && !@sock.closed?
- @sock = nil
- @retry = Time.now + RETRY_DELAY
-
- reason = "#{error.class.name}: #{error.message}"
- @status = sprintf "%s:%s DEAD (%s), will retry at %s", @host, @port, reason, @retry
- @logger.info { @status } if @logger
- end
-
- end
-
- ##
- # Base MemCache exception class.
-
- class MemCacheError < RuntimeError; end
-
- class BufferedIO < Net::BufferedIO # :nodoc:
- BUFSIZE = 1024 * 16
-
- if RUBY_VERSION < '1.9.1'
- def rbuf_fill
- begin
- @rbuf << @io.read_nonblock(BUFSIZE)
- rescue Errno::EWOULDBLOCK
- retry unless @read_timeout
- if IO.select([@io], nil, nil, @read_timeout)
- retry
- else
- raise Timeout::Error, 'IO timeout'
- end
- end
- end
- end
-
- def setsockopt(*args)
- @io.setsockopt(*args)
- end
-
- def gets
- readuntil("\n")
- end
- end
-
-end
-
-module Continuum
- POINTS_PER_SERVER = 160 # this is the default in libmemcached
-
- # Find the closest index in Continuum with value <= the given value
- def self.binary_search(ary, value, &block)
- upper = ary.size - 1
- lower = 0
- idx = 0
-
- while(lower <= upper) do
- idx = (lower + upper) / 2
- comp = ary[idx].value <=> value
-
- if comp == 0
- return idx
- elsif comp > 0
- upper = idx - 1
- else
- lower = idx + 1
- end
- end
- return upper
- end
-
- class Entry
- attr_reader :value
- attr_reader :server
-
- def initialize(val, srv)
- @value = val
- @server = srv
- end
-
- def inspect
- "<#{value}, #{server.host}:#{server.port}>"
- end
- end
-
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo.rb
deleted file mode 100644
index c8bdbeec5d..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo.rb
+++ /dev/null
@@ -1,33 +0,0 @@
-#--
-# Copyright (c) 2005-2006 Philip Ross
-#
-# Permission is hereby granted, free of charge, to any person obtaining a copy
-# of this software and associated documentation files (the "Software"), to deal
-# in the Software without restriction, including without limitation the rights
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-# copies of the Software, and to permit persons to whom the Software is
-# furnished to do so, subject to the following conditions:
-#
-# The above copyright notice and this permission notice shall be included in all
-# copies or substantial portions of the Software.
-#
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-# THE SOFTWARE.
-#++
-
-# Add the directory containing this file to the start of the load path if it
-# isn't there already.
-$:.unshift(File.dirname(__FILE__)) unless
- $:.include?(File.dirname(__FILE__)) || $:.include?(File.expand_path(File.dirname(__FILE__)))
-
-require 'tzinfo/timezone'
-# require 'tzinfo/country'
-# require 'tzinfo/tzdataparser'
-# require 'tzinfo/timezone_proxy'
-require 'tzinfo/data_timezone'
-require 'tzinfo/linked_timezone' \ No newline at end of file
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/data_timezone.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/data_timezone.rb
deleted file mode 100644
index 5eccbdf0db..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/data_timezone.rb
+++ /dev/null
@@ -1,47 +0,0 @@
-#--
-# Copyright (c) 2006 Philip Ross
-#
-# Permission is hereby granted, free of charge, to any person obtaining a copy
-# of this software and associated documentation files (the "Software"), to deal
-# in the Software without restriction, including without limitation the rights
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-# copies of the Software, and to permit persons to whom the Software is
-# furnished to do so, subject to the following conditions:
-#
-# The above copyright notice and this permission notice shall be included in all
-# copies or substantial portions of the Software.
-#
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-# THE SOFTWARE.
-#++
-
-require 'tzinfo/info_timezone'
-
-module TZInfo
-
- # A Timezone based on a DataTimezoneInfo.
- class DataTimezone < InfoTimezone #:nodoc:
-
- # Returns the TimezonePeriod for the given UTC time. utc can either be
- # a DateTime, Time or integer timestamp (Time.to_i). Any timezone
- # information in utc is ignored (it is treated as a UTC time).
- #
- # If no TimezonePeriod could be found, PeriodNotFound is raised.
- def period_for_utc(utc)
- info.period_for_utc(utc)
- end
-
- # Returns the set of TimezonePeriod instances that are valid for the given
- # local time as an array. If you just want a single period, use
- # period_for_local instead and specify how abiguities should be resolved.
- # Raises PeriodNotFound if no periods are found for the given time.
- def periods_for_local(local)
- info.periods_for_local(local)
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/data_timezone_info.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/data_timezone_info.rb
deleted file mode 100644
index a45d94554b..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/data_timezone_info.rb
+++ /dev/null
@@ -1,228 +0,0 @@
-#--
-# Copyright (c) 2006 Philip Ross
-#
-# Permission is hereby granted, free of charge, to any person obtaining a copy
-# of this software and associated documentation files (the "Software"), to deal
-# in the Software without restriction, including without limitation the rights
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-# copies of the Software, and to permit persons to whom the Software is
-# furnished to do so, subject to the following conditions:
-#
-# The above copyright notice and this permission notice shall be included in all
-# copies or substantial portions of the Software.
-#
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-# THE SOFTWARE.
-#++
-
-require 'tzinfo/time_or_datetime'
-require 'tzinfo/timezone_info'
-require 'tzinfo/timezone_offset_info'
-require 'tzinfo/timezone_period'
-require 'tzinfo/timezone_transition_info'
-
-module TZInfo
- # Thrown if no offsets have been defined when calling period_for_utc or
- # periods_for_local. Indicates an error in the timezone data.
- class NoOffsetsDefined < StandardError
- end
-
- # Represents a (non-linked) timezone defined in a data module.
- class DataTimezoneInfo < TimezoneInfo #:nodoc:
-
- # Constructs a new TimezoneInfo with its identifier.
- def initialize(identifier)
- super(identifier)
- @offsets = {}
- @transitions = []
- @previous_offset = nil
- @transitions_index = nil
- end
-
- # Defines a offset. The id uniquely identifies this offset within the
- # timezone. utc_offset and std_offset define the offset in seconds of
- # standard time from UTC and daylight savings from standard time
- # respectively. abbreviation describes the timezone offset (e.g. GMT, BST,
- # EST or EDT).
- #
- # The first offset to be defined is treated as the offset that applies
- # until the first transition. This will usually be in Local Mean Time (LMT).
- #
- # ArgumentError will be raised if the id is already defined.
- def offset(id, utc_offset, std_offset, abbreviation)
- raise ArgumentError, 'Offset already defined' if @offsets.has_key?(id)
-
- offset = TimezoneOffsetInfo.new(utc_offset, std_offset, abbreviation)
- @offsets[id] = offset
- @previous_offset = offset unless @previous_offset
- end
-
- # Defines a transition. Transitions must be defined in chronological order.
- # ArgumentError will be raised if a transition is added out of order.
- # offset_id refers to an id defined with offset. ArgumentError will be
- # raised if the offset_id cannot be found. numerator_or_time and
- # denomiator specify the time the transition occurs as. See
- # TimezoneTransitionInfo for more detail about specifying times.
- def transition(year, month, offset_id, numerator_or_time, denominator = nil)
- offset = @offsets[offset_id]
- raise ArgumentError, 'Offset not found' unless offset
-
- if @transitions_index
- if year < @last_year || (year == @last_year && month < @last_month)
- raise ArgumentError, 'Transitions must be increasing date order'
- end
-
- # Record the position of the first transition with this index.
- index = transition_index(year, month)
- @transitions_index[index] ||= @transitions.length
-
- # Fill in any gaps
- (index - 1).downto(0) do |i|
- break if @transitions_index[i]
- @transitions_index[i] = @transitions.length
- end
- else
- @transitions_index = [@transitions.length]
- @start_year = year
- @start_month = month
- end
-
- @transitions << TimezoneTransitionInfo.new(offset, @previous_offset,
- numerator_or_time, denominator)
- @last_year = year
- @last_month = month
- @previous_offset = offset
- end
-
- # Returns the TimezonePeriod for the given UTC time.
- # Raises NoOffsetsDefined if no offsets have been defined.
- def period_for_utc(utc)
- unless @transitions.empty?
- utc = TimeOrDateTime.wrap(utc)
- index = transition_index(utc.year, utc.mon)
-
- start_transition = nil
- start = transition_before_end(index)
- if start
- start.downto(0) do |i|
- if @transitions[i].at <= utc
- start_transition = @transitions[i]
- break
- end
- end
- end
-
- end_transition = nil
- start = transition_after_start(index)
- if start
- start.upto(@transitions.length - 1) do |i|
- if @transitions[i].at > utc
- end_transition = @transitions[i]
- break
- end
- end
- end
-
- if start_transition || end_transition
- TimezonePeriod.new(start_transition, end_transition)
- else
- # Won't happen since there are transitions. Must always find one
- # transition that is either >= or < the specified time.
- raise 'No transitions found in search'
- end
- else
- raise NoOffsetsDefined, 'No offsets have been defined' unless @previous_offset
- TimezonePeriod.new(nil, nil, @previous_offset)
- end
- end
-
- # Returns the set of TimezonePeriods for the given local time as an array.
- # Results returned are ordered by increasing UTC start date.
- # Returns an empty array if no periods are found for the given time.
- # Raises NoOffsetsDefined if no offsets have been defined.
- def periods_for_local(local)
- unless @transitions.empty?
- local = TimeOrDateTime.wrap(local)
- index = transition_index(local.year, local.mon)
-
- result = []
-
- start_index = transition_after_start(index - 1)
- if start_index && @transitions[start_index].local_end > local
- if start_index > 0
- if @transitions[start_index - 1].local_start <= local
- result << TimezonePeriod.new(@transitions[start_index - 1], @transitions[start_index])
- end
- else
- result << TimezonePeriod.new(nil, @transitions[start_index])
- end
- end
-
- end_index = transition_before_end(index + 1)
-
- if end_index
- start_index = end_index unless start_index
-
- start_index.upto(transition_before_end(index + 1)) do |i|
- if @transitions[i].local_start <= local
- if i + 1 < @transitions.length
- if @transitions[i + 1].local_end > local
- result << TimezonePeriod.new(@transitions[i], @transitions[i + 1])
- end
- else
- result << TimezonePeriod.new(@transitions[i], nil)
- end
- end
- end
- end
-
- result
- else
- raise NoOffsetsDefined, 'No offsets have been defined' unless @previous_offset
- [TimezonePeriod.new(nil, nil, @previous_offset)]
- end
- end
-
- private
- # Returns the index into the @transitions_index array for a given year
- # and month.
- def transition_index(year, month)
- index = (year - @start_year) * 2
- index += 1 if month > 6
- index -= 1 if @start_month > 6
- index
- end
-
- # Returns the index into @transitions of the first transition that occurs
- # on or after the start of the given index into @transitions_index.
- # Returns nil if there are no such transitions.
- def transition_after_start(index)
- if index >= @transitions_index.length
- nil
- else
- index = 0 if index < 0
- @transitions_index[index]
- end
- end
-
- # Returns the index into @transitions of the first transition that occurs
- # before the end of the given index into @transitions_index.
- # Returns nil if there are no such transitions.
- def transition_before_end(index)
- index = index + 1
-
- if index <= 0
- nil
- elsif index >= @transitions_index.length
- @transitions.length - 1
- else
- @transitions_index[index] - 1
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Algiers.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Algiers.rb
deleted file mode 100644
index 8c5f25577f..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Algiers.rb
+++ /dev/null
@@ -1,55 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Africa
- module Algiers
- include TimezoneDefinition
-
- timezone 'Africa/Algiers' do |tz|
- tz.offset :o0, 732, 0, :LMT
- tz.offset :o1, 561, 0, :PMT
- tz.offset :o2, 0, 0, :WET
- tz.offset :o3, 0, 3600, :WEST
- tz.offset :o4, 3600, 0, :CET
- tz.offset :o5, 3600, 3600, :CEST
-
- tz.transition 1891, 3, :o1, 2170625843, 900
- tz.transition 1911, 3, :o2, 69670267013, 28800
- tz.transition 1916, 6, :o3, 58104707, 24
- tz.transition 1916, 10, :o2, 58107323, 24
- tz.transition 1917, 3, :o3, 58111499, 24
- tz.transition 1917, 10, :o2, 58116227, 24
- tz.transition 1918, 3, :o3, 58119899, 24
- tz.transition 1918, 10, :o2, 58124963, 24
- tz.transition 1919, 3, :o3, 58128467, 24
- tz.transition 1919, 10, :o2, 58133699, 24
- tz.transition 1920, 2, :o3, 58136867, 24
- tz.transition 1920, 10, :o2, 58142915, 24
- tz.transition 1921, 3, :o3, 58146323, 24
- tz.transition 1921, 6, :o2, 58148699, 24
- tz.transition 1939, 9, :o3, 58308443, 24
- tz.transition 1939, 11, :o2, 4859173, 2
- tz.transition 1940, 2, :o4, 29156215, 12
- tz.transition 1944, 4, :o5, 58348405, 24
- tz.transition 1944, 10, :o4, 4862743, 2
- tz.transition 1945, 4, :o5, 58357141, 24
- tz.transition 1945, 9, :o4, 58361147, 24
- tz.transition 1946, 10, :o2, 58370411, 24
- tz.transition 1956, 1, :o4, 4871003, 2
- tz.transition 1963, 4, :o2, 58515203, 24
- tz.transition 1971, 4, :o3, 41468400
- tz.transition 1971, 9, :o2, 54774000
- tz.transition 1977, 5, :o3, 231724800
- tz.transition 1977, 10, :o4, 246236400
- tz.transition 1978, 3, :o5, 259545600
- tz.transition 1978, 9, :o4, 275274000
- tz.transition 1979, 10, :o2, 309740400
- tz.transition 1980, 4, :o3, 325468800
- tz.transition 1980, 10, :o2, 341802000
- tz.transition 1981, 5, :o4, 357523200
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Cairo.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Cairo.rb
deleted file mode 100644
index b7ed8e8244..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Cairo.rb
+++ /dev/null
@@ -1,219 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Africa
- module Cairo
- include TimezoneDefinition
-
- timezone 'Africa/Cairo' do |tz|
- tz.offset :o0, 7500, 0, :LMT
- tz.offset :o1, 7200, 0, :EET
- tz.offset :o2, 7200, 3600, :EEST
-
- tz.transition 1900, 9, :o1, 695604503, 288
- tz.transition 1940, 7, :o2, 29157905, 12
- tz.transition 1940, 9, :o1, 19439227, 8
- tz.transition 1941, 4, :o2, 29161193, 12
- tz.transition 1941, 9, :o1, 19442027, 8
- tz.transition 1942, 3, :o2, 29165405, 12
- tz.transition 1942, 10, :o1, 19445275, 8
- tz.transition 1943, 3, :o2, 29169785, 12
- tz.transition 1943, 10, :o1, 19448235, 8
- tz.transition 1944, 3, :o2, 29174177, 12
- tz.transition 1944, 10, :o1, 19451163, 8
- tz.transition 1945, 4, :o2, 29178737, 12
- tz.transition 1945, 10, :o1, 19454083, 8
- tz.transition 1957, 5, :o2, 29231621, 12
- tz.transition 1957, 9, :o1, 19488899, 8
- tz.transition 1958, 4, :o2, 29235893, 12
- tz.transition 1958, 9, :o1, 19491819, 8
- tz.transition 1959, 4, :o2, 58480547, 24
- tz.transition 1959, 9, :o1, 4873683, 2
- tz.transition 1960, 4, :o2, 58489331, 24
- tz.transition 1960, 9, :o1, 4874415, 2
- tz.transition 1961, 4, :o2, 58498091, 24
- tz.transition 1961, 9, :o1, 4875145, 2
- tz.transition 1962, 4, :o2, 58506851, 24
- tz.transition 1962, 9, :o1, 4875875, 2
- tz.transition 1963, 4, :o2, 58515611, 24
- tz.transition 1963, 9, :o1, 4876605, 2
- tz.transition 1964, 4, :o2, 58524395, 24
- tz.transition 1964, 9, :o1, 4877337, 2
- tz.transition 1965, 4, :o2, 58533155, 24
- tz.transition 1965, 9, :o1, 4878067, 2
- tz.transition 1966, 4, :o2, 58541915, 24
- tz.transition 1966, 10, :o1, 4878799, 2
- tz.transition 1967, 4, :o2, 58550675, 24
- tz.transition 1967, 10, :o1, 4879529, 2
- tz.transition 1968, 4, :o2, 58559459, 24
- tz.transition 1968, 10, :o1, 4880261, 2
- tz.transition 1969, 4, :o2, 58568219, 24
- tz.transition 1969, 10, :o1, 4880991, 2
- tz.transition 1970, 4, :o2, 10364400
- tz.transition 1970, 10, :o1, 23587200
- tz.transition 1971, 4, :o2, 41900400
- tz.transition 1971, 10, :o1, 55123200
- tz.transition 1972, 4, :o2, 73522800
- tz.transition 1972, 10, :o1, 86745600
- tz.transition 1973, 4, :o2, 105058800
- tz.transition 1973, 10, :o1, 118281600
- tz.transition 1974, 4, :o2, 136594800
- tz.transition 1974, 10, :o1, 149817600
- tz.transition 1975, 4, :o2, 168130800
- tz.transition 1975, 10, :o1, 181353600
- tz.transition 1976, 4, :o2, 199753200
- tz.transition 1976, 10, :o1, 212976000
- tz.transition 1977, 4, :o2, 231289200
- tz.transition 1977, 10, :o1, 244512000
- tz.transition 1978, 4, :o2, 262825200
- tz.transition 1978, 10, :o1, 276048000
- tz.transition 1979, 4, :o2, 294361200
- tz.transition 1979, 10, :o1, 307584000
- tz.transition 1980, 4, :o2, 325983600
- tz.transition 1980, 10, :o1, 339206400
- tz.transition 1981, 4, :o2, 357519600
- tz.transition 1981, 10, :o1, 370742400
- tz.transition 1982, 7, :o2, 396399600
- tz.transition 1982, 10, :o1, 402278400
- tz.transition 1983, 7, :o2, 426812400
- tz.transition 1983, 10, :o1, 433814400
- tz.transition 1984, 4, :o2, 452214000
- tz.transition 1984, 10, :o1, 465436800
- tz.transition 1985, 4, :o2, 483750000
- tz.transition 1985, 10, :o1, 496972800
- tz.transition 1986, 4, :o2, 515286000
- tz.transition 1986, 10, :o1, 528508800
- tz.transition 1987, 4, :o2, 546822000
- tz.transition 1987, 10, :o1, 560044800
- tz.transition 1988, 4, :o2, 578444400
- tz.transition 1988, 10, :o1, 591667200
- tz.transition 1989, 5, :o2, 610412400
- tz.transition 1989, 10, :o1, 623203200
- tz.transition 1990, 4, :o2, 641516400
- tz.transition 1990, 10, :o1, 654739200
- tz.transition 1991, 4, :o2, 673052400
- tz.transition 1991, 10, :o1, 686275200
- tz.transition 1992, 4, :o2, 704674800
- tz.transition 1992, 10, :o1, 717897600
- tz.transition 1993, 4, :o2, 736210800
- tz.transition 1993, 10, :o1, 749433600
- tz.transition 1994, 4, :o2, 767746800
- tz.transition 1994, 10, :o1, 780969600
- tz.transition 1995, 4, :o2, 799020000
- tz.transition 1995, 9, :o1, 812322000
- tz.transition 1996, 4, :o2, 830469600
- tz.transition 1996, 9, :o1, 843771600
- tz.transition 1997, 4, :o2, 861919200
- tz.transition 1997, 9, :o1, 875221200
- tz.transition 1998, 4, :o2, 893368800
- tz.transition 1998, 9, :o1, 906670800
- tz.transition 1999, 4, :o2, 925423200
- tz.transition 1999, 9, :o1, 938725200
- tz.transition 2000, 4, :o2, 956872800
- tz.transition 2000, 9, :o1, 970174800
- tz.transition 2001, 4, :o2, 988322400
- tz.transition 2001, 9, :o1, 1001624400
- tz.transition 2002, 4, :o2, 1019772000
- tz.transition 2002, 9, :o1, 1033074000
- tz.transition 2003, 4, :o2, 1051221600
- tz.transition 2003, 9, :o1, 1064523600
- tz.transition 2004, 4, :o2, 1083276000
- tz.transition 2004, 9, :o1, 1096578000
- tz.transition 2005, 4, :o2, 1114725600
- tz.transition 2005, 9, :o1, 1128027600
- tz.transition 2006, 4, :o2, 1146175200
- tz.transition 2006, 9, :o1, 1158872400
- tz.transition 2007, 4, :o2, 1177624800
- tz.transition 2007, 9, :o1, 1189112400
- tz.transition 2008, 4, :o2, 1209074400
- tz.transition 2008, 8, :o1, 1219957200
- tz.transition 2009, 4, :o2, 1240524000
- tz.transition 2009, 8, :o1, 1250802000
- tz.transition 2010, 4, :o2, 1272578400
- tz.transition 2010, 9, :o1, 1285880400
- tz.transition 2011, 4, :o2, 1304028000
- tz.transition 2011, 9, :o1, 1317330000
- tz.transition 2012, 4, :o2, 1335477600
- tz.transition 2012, 9, :o1, 1348779600
- tz.transition 2013, 4, :o2, 1366927200
- tz.transition 2013, 9, :o1, 1380229200
- tz.transition 2014, 4, :o2, 1398376800
- tz.transition 2014, 9, :o1, 1411678800
- tz.transition 2015, 4, :o2, 1429826400
- tz.transition 2015, 9, :o1, 1443128400
- tz.transition 2016, 4, :o2, 1461880800
- tz.transition 2016, 9, :o1, 1475182800
- tz.transition 2017, 4, :o2, 1493330400
- tz.transition 2017, 9, :o1, 1506632400
- tz.transition 2018, 4, :o2, 1524780000
- tz.transition 2018, 9, :o1, 1538082000
- tz.transition 2019, 4, :o2, 1556229600
- tz.transition 2019, 9, :o1, 1569531600
- tz.transition 2020, 4, :o2, 1587679200
- tz.transition 2020, 9, :o1, 1600981200
- tz.transition 2021, 4, :o2, 1619733600
- tz.transition 2021, 9, :o1, 1633035600
- tz.transition 2022, 4, :o2, 1651183200
- tz.transition 2022, 9, :o1, 1664485200
- tz.transition 2023, 4, :o2, 1682632800
- tz.transition 2023, 9, :o1, 1695934800
- tz.transition 2024, 4, :o2, 1714082400
- tz.transition 2024, 9, :o1, 1727384400
- tz.transition 2025, 4, :o2, 1745532000
- tz.transition 2025, 9, :o1, 1758834000
- tz.transition 2026, 4, :o2, 1776981600
- tz.transition 2026, 9, :o1, 1790283600
- tz.transition 2027, 4, :o2, 1809036000
- tz.transition 2027, 9, :o1, 1822338000
- tz.transition 2028, 4, :o2, 1840485600
- tz.transition 2028, 9, :o1, 1853787600
- tz.transition 2029, 4, :o2, 1871935200
- tz.transition 2029, 9, :o1, 1885237200
- tz.transition 2030, 4, :o2, 1903384800
- tz.transition 2030, 9, :o1, 1916686800
- tz.transition 2031, 4, :o2, 1934834400
- tz.transition 2031, 9, :o1, 1948136400
- tz.transition 2032, 4, :o2, 1966888800
- tz.transition 2032, 9, :o1, 1980190800
- tz.transition 2033, 4, :o2, 1998338400
- tz.transition 2033, 9, :o1, 2011640400
- tz.transition 2034, 4, :o2, 2029788000
- tz.transition 2034, 9, :o1, 2043090000
- tz.transition 2035, 4, :o2, 2061237600
- tz.transition 2035, 9, :o1, 2074539600
- tz.transition 2036, 4, :o2, 2092687200
- tz.transition 2036, 9, :o1, 2105989200
- tz.transition 2037, 4, :o2, 2124136800
- tz.transition 2037, 9, :o1, 2137438800
- tz.transition 2038, 4, :o2, 29586521, 12
- tz.transition 2038, 9, :o1, 19725579, 8
- tz.transition 2039, 4, :o2, 29590889, 12
- tz.transition 2039, 9, :o1, 19728491, 8
- tz.transition 2040, 4, :o2, 29595257, 12
- tz.transition 2040, 9, :o1, 19731403, 8
- tz.transition 2041, 4, :o2, 29599625, 12
- tz.transition 2041, 9, :o1, 19734315, 8
- tz.transition 2042, 4, :o2, 29603993, 12
- tz.transition 2042, 9, :o1, 19737227, 8
- tz.transition 2043, 4, :o2, 29608361, 12
- tz.transition 2043, 9, :o1, 19740139, 8
- tz.transition 2044, 4, :o2, 29612813, 12
- tz.transition 2044, 9, :o1, 19743107, 8
- tz.transition 2045, 4, :o2, 29617181, 12
- tz.transition 2045, 9, :o1, 19746019, 8
- tz.transition 2046, 4, :o2, 29621549, 12
- tz.transition 2046, 9, :o1, 19748931, 8
- tz.transition 2047, 4, :o2, 29625917, 12
- tz.transition 2047, 9, :o1, 19751843, 8
- tz.transition 2048, 4, :o2, 29630285, 12
- tz.transition 2048, 9, :o1, 19754755, 8
- tz.transition 2049, 4, :o2, 29634737, 12
- tz.transition 2049, 9, :o1, 19757723, 8
- tz.transition 2050, 4, :o2, 29639105, 12
- tz.transition 2050, 9, :o1, 19760635, 8
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Casablanca.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Casablanca.rb
deleted file mode 100644
index 18d73c93a0..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Casablanca.rb
+++ /dev/null
@@ -1,42 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Africa
- module Casablanca
- include TimezoneDefinition
-
- timezone 'Africa/Casablanca' do |tz|
- tz.offset :o0, -1820, 0, :LMT
- tz.offset :o1, 0, 0, :WET
- tz.offset :o2, 0, 3600, :WEST
- tz.offset :o3, 3600, 0, :CET
-
- tz.transition 1913, 10, :o1, 10454687371, 4320
- tz.transition 1939, 9, :o2, 4859037, 2
- tz.transition 1939, 11, :o1, 58310075, 24
- tz.transition 1940, 2, :o2, 4859369, 2
- tz.transition 1945, 11, :o1, 58362659, 24
- tz.transition 1950, 6, :o2, 4866887, 2
- tz.transition 1950, 10, :o1, 58406003, 24
- tz.transition 1967, 6, :o2, 2439645, 1
- tz.transition 1967, 9, :o1, 58554347, 24
- tz.transition 1974, 6, :o2, 141264000
- tz.transition 1974, 8, :o1, 147222000
- tz.transition 1976, 5, :o2, 199756800
- tz.transition 1976, 7, :o1, 207702000
- tz.transition 1977, 5, :o2, 231292800
- tz.transition 1977, 9, :o1, 244249200
- tz.transition 1978, 6, :o2, 265507200
- tz.transition 1978, 8, :o1, 271033200
- tz.transition 1984, 3, :o3, 448243200
- tz.transition 1985, 12, :o1, 504918000
- tz.transition 2008, 6, :o2, 1212278400
- tz.transition 2008, 8, :o1, 1220223600
- tz.transition 2009, 6, :o2, 1243814400
- tz.transition 2009, 8, :o1, 1250809200
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Harare.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Harare.rb
deleted file mode 100644
index 070c95ae0f..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Harare.rb
+++ /dev/null
@@ -1,18 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Africa
- module Harare
- include TimezoneDefinition
-
- timezone 'Africa/Harare' do |tz|
- tz.offset :o0, 7452, 0, :LMT
- tz.offset :o1, 7200, 0, :CAT
-
- tz.transition 1903, 2, :o1, 1932939531, 800
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Johannesburg.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Johannesburg.rb
deleted file mode 100644
index f0af0d8e33..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Johannesburg.rb
+++ /dev/null
@@ -1,25 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Africa
- module Johannesburg
- include TimezoneDefinition
-
- timezone 'Africa/Johannesburg' do |tz|
- tz.offset :o0, 6720, 0, :LMT
- tz.offset :o1, 5400, 0, :SAST
- tz.offset :o2, 7200, 0, :SAST
- tz.offset :o3, 7200, 3600, :SAST
-
- tz.transition 1892, 2, :o1, 108546139, 45
- tz.transition 1903, 2, :o2, 38658791, 16
- tz.transition 1942, 9, :o3, 4861245, 2
- tz.transition 1943, 3, :o2, 58339307, 24
- tz.transition 1943, 9, :o3, 4861973, 2
- tz.transition 1944, 3, :o2, 58348043, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Monrovia.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Monrovia.rb
deleted file mode 100644
index 40e711fa44..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Monrovia.rb
+++ /dev/null
@@ -1,22 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Africa
- module Monrovia
- include TimezoneDefinition
-
- timezone 'Africa/Monrovia' do |tz|
- tz.offset :o0, -2588, 0, :LMT
- tz.offset :o1, -2588, 0, :MMT
- tz.offset :o2, -2670, 0, :LRT
- tz.offset :o3, 0, 0, :GMT
-
- tz.transition 1882, 1, :o1, 52022445047, 21600
- tz.transition 1919, 3, :o2, 52315600247, 21600
- tz.transition 1972, 5, :o3, 73529070
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Nairobi.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Nairobi.rb
deleted file mode 100644
index 7b0a2f43be..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Africa/Nairobi.rb
+++ /dev/null
@@ -1,23 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Africa
- module Nairobi
- include TimezoneDefinition
-
- timezone 'Africa/Nairobi' do |tz|
- tz.offset :o0, 8836, 0, :LMT
- tz.offset :o1, 10800, 0, :EAT
- tz.offset :o2, 9000, 0, :BEAT
- tz.offset :o3, 9885, 0, :BEAUT
-
- tz.transition 1928, 6, :o1, 52389253391, 21600
- tz.transition 1929, 12, :o2, 19407819, 8
- tz.transition 1939, 12, :o3, 116622211, 48
- tz.transition 1959, 12, :o1, 14036742061, 5760
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Argentina/Buenos_Aires.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Argentina/Buenos_Aires.rb
deleted file mode 100644
index 307f9546de..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Argentina/Buenos_Aires.rb
+++ /dev/null
@@ -1,84 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module Argentina
- module Buenos_Aires
- include TimezoneDefinition
-
- timezone 'America/Argentina/Buenos_Aires' do |tz|
- tz.offset :o0, -14028, 0, :LMT
- tz.offset :o1, -15408, 0, :CMT
- tz.offset :o2, -14400, 0, :ART
- tz.offset :o3, -14400, 3600, :ARST
- tz.offset :o4, -10800, 0, :ART
- tz.offset :o5, -10800, 3600, :ARST
-
- tz.transition 1894, 10, :o1, 17374555169, 7200
- tz.transition 1920, 5, :o2, 1453467407, 600
- tz.transition 1930, 12, :o3, 7278935, 3
- tz.transition 1931, 4, :o2, 19411461, 8
- tz.transition 1931, 10, :o3, 7279889, 3
- tz.transition 1932, 3, :o2, 19414141, 8
- tz.transition 1932, 11, :o3, 7281038, 3
- tz.transition 1933, 3, :o2, 19417061, 8
- tz.transition 1933, 11, :o3, 7282133, 3
- tz.transition 1934, 3, :o2, 19419981, 8
- tz.transition 1934, 11, :o3, 7283228, 3
- tz.transition 1935, 3, :o2, 19422901, 8
- tz.transition 1935, 11, :o3, 7284323, 3
- tz.transition 1936, 3, :o2, 19425829, 8
- tz.transition 1936, 11, :o3, 7285421, 3
- tz.transition 1937, 3, :o2, 19428749, 8
- tz.transition 1937, 11, :o3, 7286516, 3
- tz.transition 1938, 3, :o2, 19431669, 8
- tz.transition 1938, 11, :o3, 7287611, 3
- tz.transition 1939, 3, :o2, 19434589, 8
- tz.transition 1939, 11, :o3, 7288706, 3
- tz.transition 1940, 3, :o2, 19437517, 8
- tz.transition 1940, 7, :o3, 7289435, 3
- tz.transition 1941, 6, :o2, 19441285, 8
- tz.transition 1941, 10, :o3, 7290848, 3
- tz.transition 1943, 8, :o2, 19447501, 8
- tz.transition 1943, 10, :o3, 7293038, 3
- tz.transition 1946, 3, :o2, 19455045, 8
- tz.transition 1946, 10, :o3, 7296284, 3
- tz.transition 1963, 10, :o2, 19506429, 8
- tz.transition 1963, 12, :o3, 7315136, 3
- tz.transition 1964, 3, :o2, 19507645, 8
- tz.transition 1964, 10, :o3, 7316051, 3
- tz.transition 1965, 3, :o2, 19510565, 8
- tz.transition 1965, 10, :o3, 7317146, 3
- tz.transition 1966, 3, :o2, 19513485, 8
- tz.transition 1966, 10, :o3, 7318241, 3
- tz.transition 1967, 4, :o2, 19516661, 8
- tz.transition 1967, 10, :o3, 7319294, 3
- tz.transition 1968, 4, :o2, 19519629, 8
- tz.transition 1968, 10, :o3, 7320407, 3
- tz.transition 1969, 4, :o2, 19522541, 8
- tz.transition 1969, 10, :o4, 7321499, 3
- tz.transition 1974, 1, :o5, 128142000
- tz.transition 1974, 5, :o4, 136605600
- tz.transition 1988, 12, :o5, 596948400
- tz.transition 1989, 3, :o4, 605066400
- tz.transition 1989, 10, :o5, 624423600
- tz.transition 1990, 3, :o4, 636516000
- tz.transition 1990, 10, :o5, 656478000
- tz.transition 1991, 3, :o4, 667965600
- tz.transition 1991, 10, :o5, 687927600
- tz.transition 1992, 3, :o4, 699415200
- tz.transition 1992, 10, :o5, 719377200
- tz.transition 1993, 3, :o4, 731469600
- tz.transition 1999, 10, :o3, 938919600
- tz.transition 2000, 3, :o4, 952052400
- tz.transition 2007, 12, :o5, 1198983600
- tz.transition 2008, 3, :o4, 1205632800
- tz.transition 2008, 10, :o5, 1224385200
- tz.transition 2009, 3, :o4, 1237082400
- end
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Argentina/San_Juan.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Argentina/San_Juan.rb
deleted file mode 100644
index ba8be4705f..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Argentina/San_Juan.rb
+++ /dev/null
@@ -1,86 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module Argentina
- module San_Juan
- include TimezoneDefinition
-
- timezone 'America/Argentina/San_Juan' do |tz|
- tz.offset :o0, -16444, 0, :LMT
- tz.offset :o1, -15408, 0, :CMT
- tz.offset :o2, -14400, 0, :ART
- tz.offset :o3, -14400, 3600, :ARST
- tz.offset :o4, -10800, 0, :ART
- tz.offset :o5, -10800, 3600, :ARST
- tz.offset :o6, -14400, 0, :WART
-
- tz.transition 1894, 10, :o1, 52123666111, 21600
- tz.transition 1920, 5, :o2, 1453467407, 600
- tz.transition 1930, 12, :o3, 7278935, 3
- tz.transition 1931, 4, :o2, 19411461, 8
- tz.transition 1931, 10, :o3, 7279889, 3
- tz.transition 1932, 3, :o2, 19414141, 8
- tz.transition 1932, 11, :o3, 7281038, 3
- tz.transition 1933, 3, :o2, 19417061, 8
- tz.transition 1933, 11, :o3, 7282133, 3
- tz.transition 1934, 3, :o2, 19419981, 8
- tz.transition 1934, 11, :o3, 7283228, 3
- tz.transition 1935, 3, :o2, 19422901, 8
- tz.transition 1935, 11, :o3, 7284323, 3
- tz.transition 1936, 3, :o2, 19425829, 8
- tz.transition 1936, 11, :o3, 7285421, 3
- tz.transition 1937, 3, :o2, 19428749, 8
- tz.transition 1937, 11, :o3, 7286516, 3
- tz.transition 1938, 3, :o2, 19431669, 8
- tz.transition 1938, 11, :o3, 7287611, 3
- tz.transition 1939, 3, :o2, 19434589, 8
- tz.transition 1939, 11, :o3, 7288706, 3
- tz.transition 1940, 3, :o2, 19437517, 8
- tz.transition 1940, 7, :o3, 7289435, 3
- tz.transition 1941, 6, :o2, 19441285, 8
- tz.transition 1941, 10, :o3, 7290848, 3
- tz.transition 1943, 8, :o2, 19447501, 8
- tz.transition 1943, 10, :o3, 7293038, 3
- tz.transition 1946, 3, :o2, 19455045, 8
- tz.transition 1946, 10, :o3, 7296284, 3
- tz.transition 1963, 10, :o2, 19506429, 8
- tz.transition 1963, 12, :o3, 7315136, 3
- tz.transition 1964, 3, :o2, 19507645, 8
- tz.transition 1964, 10, :o3, 7316051, 3
- tz.transition 1965, 3, :o2, 19510565, 8
- tz.transition 1965, 10, :o3, 7317146, 3
- tz.transition 1966, 3, :o2, 19513485, 8
- tz.transition 1966, 10, :o3, 7318241, 3
- tz.transition 1967, 4, :o2, 19516661, 8
- tz.transition 1967, 10, :o3, 7319294, 3
- tz.transition 1968, 4, :o2, 19519629, 8
- tz.transition 1968, 10, :o3, 7320407, 3
- tz.transition 1969, 4, :o2, 19522541, 8
- tz.transition 1969, 10, :o4, 7321499, 3
- tz.transition 1974, 1, :o5, 128142000
- tz.transition 1974, 5, :o4, 136605600
- tz.transition 1988, 12, :o5, 596948400
- tz.transition 1989, 3, :o4, 605066400
- tz.transition 1989, 10, :o5, 624423600
- tz.transition 1990, 3, :o4, 636516000
- tz.transition 1990, 10, :o5, 656478000
- tz.transition 1991, 3, :o6, 667792800
- tz.transition 1991, 5, :o4, 673588800
- tz.transition 1991, 10, :o5, 687927600
- tz.transition 1992, 3, :o4, 699415200
- tz.transition 1992, 10, :o5, 719377200
- tz.transition 1993, 3, :o4, 731469600
- tz.transition 1999, 10, :o3, 938919600
- tz.transition 2000, 3, :o4, 952052400
- tz.transition 2004, 5, :o6, 1085972400
- tz.transition 2004, 7, :o4, 1090728000
- tz.transition 2007, 12, :o5, 1198983600
- tz.transition 2008, 3, :o4, 1205632800
- end
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Bogota.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Bogota.rb
deleted file mode 100644
index ef96435c6a..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Bogota.rb
+++ /dev/null
@@ -1,23 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module Bogota
- include TimezoneDefinition
-
- timezone 'America/Bogota' do |tz|
- tz.offset :o0, -17780, 0, :LMT
- tz.offset :o1, -17780, 0, :BMT
- tz.offset :o2, -18000, 0, :COT
- tz.offset :o3, -18000, 3600, :COST
-
- tz.transition 1884, 3, :o1, 10407954409, 4320
- tz.transition 1914, 11, :o2, 10456385929, 4320
- tz.transition 1992, 5, :o3, 704869200
- tz.transition 1993, 4, :o2, 733896000
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Caracas.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Caracas.rb
deleted file mode 100644
index 27392a540a..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Caracas.rb
+++ /dev/null
@@ -1,23 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module Caracas
- include TimezoneDefinition
-
- timezone 'America/Caracas' do |tz|
- tz.offset :o0, -16064, 0, :LMT
- tz.offset :o1, -16060, 0, :CMT
- tz.offset :o2, -16200, 0, :VET
- tz.offset :o3, -14400, 0, :VET
-
- tz.transition 1890, 1, :o1, 1627673863, 675
- tz.transition 1912, 2, :o2, 10452001043, 4320
- tz.transition 1965, 1, :o3, 39020187, 16
- tz.transition 2007, 12, :o2, 1197183600
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Chicago.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Chicago.rb
deleted file mode 100644
index 0996857cf0..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Chicago.rb
+++ /dev/null
@@ -1,283 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module Chicago
- include TimezoneDefinition
-
- timezone 'America/Chicago' do |tz|
- tz.offset :o0, -21036, 0, :LMT
- tz.offset :o1, -21600, 0, :CST
- tz.offset :o2, -21600, 3600, :CDT
- tz.offset :o3, -18000, 0, :EST
- tz.offset :o4, -21600, 3600, :CWT
- tz.offset :o5, -21600, 3600, :CPT
-
- tz.transition 1883, 11, :o1, 9636533, 4
- tz.transition 1918, 3, :o2, 14530103, 6
- tz.transition 1918, 10, :o1, 58125451, 24
- tz.transition 1919, 3, :o2, 14532287, 6
- tz.transition 1919, 10, :o1, 58134187, 24
- tz.transition 1920, 6, :o2, 14534933, 6
- tz.transition 1920, 10, :o1, 58143091, 24
- tz.transition 1921, 3, :o2, 14536655, 6
- tz.transition 1921, 10, :o1, 58151827, 24
- tz.transition 1922, 4, :o2, 14539049, 6
- tz.transition 1922, 9, :o1, 58159723, 24
- tz.transition 1923, 4, :o2, 14541233, 6
- tz.transition 1923, 9, :o1, 58168627, 24
- tz.transition 1924, 4, :o2, 14543417, 6
- tz.transition 1924, 9, :o1, 58177363, 24
- tz.transition 1925, 4, :o2, 14545601, 6
- tz.transition 1925, 9, :o1, 58186099, 24
- tz.transition 1926, 4, :o2, 14547785, 6
- tz.transition 1926, 9, :o1, 58194835, 24
- tz.transition 1927, 4, :o2, 14549969, 6
- tz.transition 1927, 9, :o1, 58203571, 24
- tz.transition 1928, 4, :o2, 14552195, 6
- tz.transition 1928, 9, :o1, 58212475, 24
- tz.transition 1929, 4, :o2, 14554379, 6
- tz.transition 1929, 9, :o1, 58221211, 24
- tz.transition 1930, 4, :o2, 14556563, 6
- tz.transition 1930, 9, :o1, 58229947, 24
- tz.transition 1931, 4, :o2, 14558747, 6
- tz.transition 1931, 9, :o1, 58238683, 24
- tz.transition 1932, 4, :o2, 14560931, 6
- tz.transition 1932, 9, :o1, 58247419, 24
- tz.transition 1933, 4, :o2, 14563157, 6
- tz.transition 1933, 9, :o1, 58256155, 24
- tz.transition 1934, 4, :o2, 14565341, 6
- tz.transition 1934, 9, :o1, 58265059, 24
- tz.transition 1935, 4, :o2, 14567525, 6
- tz.transition 1935, 9, :o1, 58273795, 24
- tz.transition 1936, 3, :o3, 14569373, 6
- tz.transition 1936, 11, :o1, 58283707, 24
- tz.transition 1937, 4, :o2, 14571893, 6
- tz.transition 1937, 9, :o1, 58291267, 24
- tz.transition 1938, 4, :o2, 14574077, 6
- tz.transition 1938, 9, :o1, 58300003, 24
- tz.transition 1939, 4, :o2, 14576303, 6
- tz.transition 1939, 9, :o1, 58308739, 24
- tz.transition 1940, 4, :o2, 14578487, 6
- tz.transition 1940, 9, :o1, 58317643, 24
- tz.transition 1941, 4, :o2, 14580671, 6
- tz.transition 1941, 9, :o1, 58326379, 24
- tz.transition 1942, 2, :o4, 14582399, 6
- tz.transition 1945, 8, :o5, 58360379, 24
- tz.transition 1945, 9, :o1, 58361491, 24
- tz.transition 1946, 4, :o2, 14591633, 6
- tz.transition 1946, 9, :o1, 58370227, 24
- tz.transition 1947, 4, :o2, 14593817, 6
- tz.transition 1947, 9, :o1, 58378963, 24
- tz.transition 1948, 4, :o2, 14596001, 6
- tz.transition 1948, 9, :o1, 58387699, 24
- tz.transition 1949, 4, :o2, 14598185, 6
- tz.transition 1949, 9, :o1, 58396435, 24
- tz.transition 1950, 4, :o2, 14600411, 6
- tz.transition 1950, 9, :o1, 58405171, 24
- tz.transition 1951, 4, :o2, 14602595, 6
- tz.transition 1951, 9, :o1, 58414075, 24
- tz.transition 1952, 4, :o2, 14604779, 6
- tz.transition 1952, 9, :o1, 58422811, 24
- tz.transition 1953, 4, :o2, 14606963, 6
- tz.transition 1953, 9, :o1, 58431547, 24
- tz.transition 1954, 4, :o2, 14609147, 6
- tz.transition 1954, 9, :o1, 58440283, 24
- tz.transition 1955, 4, :o2, 14611331, 6
- tz.transition 1955, 10, :o1, 58449859, 24
- tz.transition 1956, 4, :o2, 14613557, 6
- tz.transition 1956, 10, :o1, 58458595, 24
- tz.transition 1957, 4, :o2, 14615741, 6
- tz.transition 1957, 10, :o1, 58467331, 24
- tz.transition 1958, 4, :o2, 14617925, 6
- tz.transition 1958, 10, :o1, 58476067, 24
- tz.transition 1959, 4, :o2, 14620109, 6
- tz.transition 1959, 10, :o1, 58484803, 24
- tz.transition 1960, 4, :o2, 14622293, 6
- tz.transition 1960, 10, :o1, 58493707, 24
- tz.transition 1961, 4, :o2, 14624519, 6
- tz.transition 1961, 10, :o1, 58502443, 24
- tz.transition 1962, 4, :o2, 14626703, 6
- tz.transition 1962, 10, :o1, 58511179, 24
- tz.transition 1963, 4, :o2, 14628887, 6
- tz.transition 1963, 10, :o1, 58519915, 24
- tz.transition 1964, 4, :o2, 14631071, 6
- tz.transition 1964, 10, :o1, 58528651, 24
- tz.transition 1965, 4, :o2, 14633255, 6
- tz.transition 1965, 10, :o1, 58537555, 24
- tz.transition 1966, 4, :o2, 14635439, 6
- tz.transition 1966, 10, :o1, 58546291, 24
- tz.transition 1967, 4, :o2, 14637665, 6
- tz.transition 1967, 10, :o1, 58555027, 24
- tz.transition 1968, 4, :o2, 14639849, 6
- tz.transition 1968, 10, :o1, 58563763, 24
- tz.transition 1969, 4, :o2, 14642033, 6
- tz.transition 1969, 10, :o1, 58572499, 24
- tz.transition 1970, 4, :o2, 9964800
- tz.transition 1970, 10, :o1, 25686000
- tz.transition 1971, 4, :o2, 41414400
- tz.transition 1971, 10, :o1, 57740400
- tz.transition 1972, 4, :o2, 73468800
- tz.transition 1972, 10, :o1, 89190000
- tz.transition 1973, 4, :o2, 104918400
- tz.transition 1973, 10, :o1, 120639600
- tz.transition 1974, 1, :o2, 126691200
- tz.transition 1974, 10, :o1, 152089200
- tz.transition 1975, 2, :o2, 162374400
- tz.transition 1975, 10, :o1, 183538800
- tz.transition 1976, 4, :o2, 199267200
- tz.transition 1976, 10, :o1, 215593200
- tz.transition 1977, 4, :o2, 230716800
- tz.transition 1977, 10, :o1, 247042800
- tz.transition 1978, 4, :o2, 262771200
- tz.transition 1978, 10, :o1, 278492400
- tz.transition 1979, 4, :o2, 294220800
- tz.transition 1979, 10, :o1, 309942000
- tz.transition 1980, 4, :o2, 325670400
- tz.transition 1980, 10, :o1, 341391600
- tz.transition 1981, 4, :o2, 357120000
- tz.transition 1981, 10, :o1, 372841200
- tz.transition 1982, 4, :o2, 388569600
- tz.transition 1982, 10, :o1, 404895600
- tz.transition 1983, 4, :o2, 420019200
- tz.transition 1983, 10, :o1, 436345200
- tz.transition 1984, 4, :o2, 452073600
- tz.transition 1984, 10, :o1, 467794800
- tz.transition 1985, 4, :o2, 483523200
- tz.transition 1985, 10, :o1, 499244400
- tz.transition 1986, 4, :o2, 514972800
- tz.transition 1986, 10, :o1, 530694000
- tz.transition 1987, 4, :o2, 544608000
- tz.transition 1987, 10, :o1, 562143600
- tz.transition 1988, 4, :o2, 576057600
- tz.transition 1988, 10, :o1, 594198000
- tz.transition 1989, 4, :o2, 607507200
- tz.transition 1989, 10, :o1, 625647600
- tz.transition 1990, 4, :o2, 638956800
- tz.transition 1990, 10, :o1, 657097200
- tz.transition 1991, 4, :o2, 671011200
- tz.transition 1991, 10, :o1, 688546800
- tz.transition 1992, 4, :o2, 702460800
- tz.transition 1992, 10, :o1, 719996400
- tz.transition 1993, 4, :o2, 733910400
- tz.transition 1993, 10, :o1, 752050800
- tz.transition 1994, 4, :o2, 765360000
- tz.transition 1994, 10, :o1, 783500400
- tz.transition 1995, 4, :o2, 796809600
- tz.transition 1995, 10, :o1, 814950000
- tz.transition 1996, 4, :o2, 828864000
- tz.transition 1996, 10, :o1, 846399600
- tz.transition 1997, 4, :o2, 860313600
- tz.transition 1997, 10, :o1, 877849200
- tz.transition 1998, 4, :o2, 891763200
- tz.transition 1998, 10, :o1, 909298800
- tz.transition 1999, 4, :o2, 923212800
- tz.transition 1999, 10, :o1, 941353200
- tz.transition 2000, 4, :o2, 954662400
- tz.transition 2000, 10, :o1, 972802800
- tz.transition 2001, 4, :o2, 986112000
- tz.transition 2001, 10, :o1, 1004252400
- tz.transition 2002, 4, :o2, 1018166400
- tz.transition 2002, 10, :o1, 1035702000
- tz.transition 2003, 4, :o2, 1049616000
- tz.transition 2003, 10, :o1, 1067151600
- tz.transition 2004, 4, :o2, 1081065600
- tz.transition 2004, 10, :o1, 1099206000
- tz.transition 2005, 4, :o2, 1112515200
- tz.transition 2005, 10, :o1, 1130655600
- tz.transition 2006, 4, :o2, 1143964800
- tz.transition 2006, 10, :o1, 1162105200
- tz.transition 2007, 3, :o2, 1173600000
- tz.transition 2007, 11, :o1, 1194159600
- tz.transition 2008, 3, :o2, 1205049600
- tz.transition 2008, 11, :o1, 1225609200
- tz.transition 2009, 3, :o2, 1236499200
- tz.transition 2009, 11, :o1, 1257058800
- tz.transition 2010, 3, :o2, 1268553600
- tz.transition 2010, 11, :o1, 1289113200
- tz.transition 2011, 3, :o2, 1300003200
- tz.transition 2011, 11, :o1, 1320562800
- tz.transition 2012, 3, :o2, 1331452800
- tz.transition 2012, 11, :o1, 1352012400
- tz.transition 2013, 3, :o2, 1362902400
- tz.transition 2013, 11, :o1, 1383462000
- tz.transition 2014, 3, :o2, 1394352000
- tz.transition 2014, 11, :o1, 1414911600
- tz.transition 2015, 3, :o2, 1425801600
- tz.transition 2015, 11, :o1, 1446361200
- tz.transition 2016, 3, :o2, 1457856000
- tz.transition 2016, 11, :o1, 1478415600
- tz.transition 2017, 3, :o2, 1489305600
- tz.transition 2017, 11, :o1, 1509865200
- tz.transition 2018, 3, :o2, 1520755200
- tz.transition 2018, 11, :o1, 1541314800
- tz.transition 2019, 3, :o2, 1552204800
- tz.transition 2019, 11, :o1, 1572764400
- tz.transition 2020, 3, :o2, 1583654400
- tz.transition 2020, 11, :o1, 1604214000
- tz.transition 2021, 3, :o2, 1615708800
- tz.transition 2021, 11, :o1, 1636268400
- tz.transition 2022, 3, :o2, 1647158400
- tz.transition 2022, 11, :o1, 1667718000
- tz.transition 2023, 3, :o2, 1678608000
- tz.transition 2023, 11, :o1, 1699167600
- tz.transition 2024, 3, :o2, 1710057600
- tz.transition 2024, 11, :o1, 1730617200
- tz.transition 2025, 3, :o2, 1741507200
- tz.transition 2025, 11, :o1, 1762066800
- tz.transition 2026, 3, :o2, 1772956800
- tz.transition 2026, 11, :o1, 1793516400
- tz.transition 2027, 3, :o2, 1805011200
- tz.transition 2027, 11, :o1, 1825570800
- tz.transition 2028, 3, :o2, 1836460800
- tz.transition 2028, 11, :o1, 1857020400
- tz.transition 2029, 3, :o2, 1867910400
- tz.transition 2029, 11, :o1, 1888470000
- tz.transition 2030, 3, :o2, 1899360000
- tz.transition 2030, 11, :o1, 1919919600
- tz.transition 2031, 3, :o2, 1930809600
- tz.transition 2031, 11, :o1, 1951369200
- tz.transition 2032, 3, :o2, 1962864000
- tz.transition 2032, 11, :o1, 1983423600
- tz.transition 2033, 3, :o2, 1994313600
- tz.transition 2033, 11, :o1, 2014873200
- tz.transition 2034, 3, :o2, 2025763200
- tz.transition 2034, 11, :o1, 2046322800
- tz.transition 2035, 3, :o2, 2057212800
- tz.transition 2035, 11, :o1, 2077772400
- tz.transition 2036, 3, :o2, 2088662400
- tz.transition 2036, 11, :o1, 2109222000
- tz.transition 2037, 3, :o2, 2120112000
- tz.transition 2037, 11, :o1, 2140671600
- tz.transition 2038, 3, :o2, 14792981, 6
- tz.transition 2038, 11, :o1, 59177635, 24
- tz.transition 2039, 3, :o2, 14795165, 6
- tz.transition 2039, 11, :o1, 59186371, 24
- tz.transition 2040, 3, :o2, 14797349, 6
- tz.transition 2040, 11, :o1, 59195107, 24
- tz.transition 2041, 3, :o2, 14799533, 6
- tz.transition 2041, 11, :o1, 59203843, 24
- tz.transition 2042, 3, :o2, 14801717, 6
- tz.transition 2042, 11, :o1, 59212579, 24
- tz.transition 2043, 3, :o2, 14803901, 6
- tz.transition 2043, 11, :o1, 59221315, 24
- tz.transition 2044, 3, :o2, 14806127, 6
- tz.transition 2044, 11, :o1, 59230219, 24
- tz.transition 2045, 3, :o2, 14808311, 6
- tz.transition 2045, 11, :o1, 59238955, 24
- tz.transition 2046, 3, :o2, 14810495, 6
- tz.transition 2046, 11, :o1, 59247691, 24
- tz.transition 2047, 3, :o2, 14812679, 6
- tz.transition 2047, 11, :o1, 59256427, 24
- tz.transition 2048, 3, :o2, 14814863, 6
- tz.transition 2048, 11, :o1, 59265163, 24
- tz.transition 2049, 3, :o2, 14817089, 6
- tz.transition 2049, 11, :o1, 59274067, 24
- tz.transition 2050, 3, :o2, 14819273, 6
- tz.transition 2050, 11, :o1, 59282803, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Chihuahua.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Chihuahua.rb
deleted file mode 100644
index 1710b57c79..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Chihuahua.rb
+++ /dev/null
@@ -1,136 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module Chihuahua
- include TimezoneDefinition
-
- timezone 'America/Chihuahua' do |tz|
- tz.offset :o0, -25460, 0, :LMT
- tz.offset :o1, -25200, 0, :MST
- tz.offset :o2, -21600, 0, :CST
- tz.offset :o3, -21600, 3600, :CDT
- tz.offset :o4, -25200, 3600, :MDT
-
- tz.transition 1922, 1, :o1, 58153339, 24
- tz.transition 1927, 6, :o2, 9700171, 4
- tz.transition 1930, 11, :o1, 9705183, 4
- tz.transition 1931, 5, :o2, 9705855, 4
- tz.transition 1931, 10, :o1, 9706463, 4
- tz.transition 1932, 4, :o2, 58243171, 24
- tz.transition 1996, 4, :o3, 828864000
- tz.transition 1996, 10, :o2, 846399600
- tz.transition 1997, 4, :o3, 860313600
- tz.transition 1997, 10, :o2, 877849200
- tz.transition 1998, 4, :o4, 891766800
- tz.transition 1998, 10, :o1, 909302400
- tz.transition 1999, 4, :o4, 923216400
- tz.transition 1999, 10, :o1, 941356800
- tz.transition 2000, 4, :o4, 954666000
- tz.transition 2000, 10, :o1, 972806400
- tz.transition 2001, 5, :o4, 989139600
- tz.transition 2001, 9, :o1, 1001836800
- tz.transition 2002, 4, :o4, 1018170000
- tz.transition 2002, 10, :o1, 1035705600
- tz.transition 2003, 4, :o4, 1049619600
- tz.transition 2003, 10, :o1, 1067155200
- tz.transition 2004, 4, :o4, 1081069200
- tz.transition 2004, 10, :o1, 1099209600
- tz.transition 2005, 4, :o4, 1112518800
- tz.transition 2005, 10, :o1, 1130659200
- tz.transition 2006, 4, :o4, 1143968400
- tz.transition 2006, 10, :o1, 1162108800
- tz.transition 2007, 4, :o4, 1175418000
- tz.transition 2007, 10, :o1, 1193558400
- tz.transition 2008, 4, :o4, 1207472400
- tz.transition 2008, 10, :o1, 1225008000
- tz.transition 2009, 4, :o4, 1238922000
- tz.transition 2009, 10, :o1, 1256457600
- tz.transition 2010, 4, :o4, 1270371600
- tz.transition 2010, 10, :o1, 1288512000
- tz.transition 2011, 4, :o4, 1301821200
- tz.transition 2011, 10, :o1, 1319961600
- tz.transition 2012, 4, :o4, 1333270800
- tz.transition 2012, 10, :o1, 1351411200
- tz.transition 2013, 4, :o4, 1365325200
- tz.transition 2013, 10, :o1, 1382860800
- tz.transition 2014, 4, :o4, 1396774800
- tz.transition 2014, 10, :o1, 1414310400
- tz.transition 2015, 4, :o4, 1428224400
- tz.transition 2015, 10, :o1, 1445760000
- tz.transition 2016, 4, :o4, 1459674000
- tz.transition 2016, 10, :o1, 1477814400
- tz.transition 2017, 4, :o4, 1491123600
- tz.transition 2017, 10, :o1, 1509264000
- tz.transition 2018, 4, :o4, 1522573200
- tz.transition 2018, 10, :o1, 1540713600
- tz.transition 2019, 4, :o4, 1554627600
- tz.transition 2019, 10, :o1, 1572163200
- tz.transition 2020, 4, :o4, 1586077200
- tz.transition 2020, 10, :o1, 1603612800
- tz.transition 2021, 4, :o4, 1617526800
- tz.transition 2021, 10, :o1, 1635667200
- tz.transition 2022, 4, :o4, 1648976400
- tz.transition 2022, 10, :o1, 1667116800
- tz.transition 2023, 4, :o4, 1680426000
- tz.transition 2023, 10, :o1, 1698566400
- tz.transition 2024, 4, :o4, 1712480400
- tz.transition 2024, 10, :o1, 1730016000
- tz.transition 2025, 4, :o4, 1743930000
- tz.transition 2025, 10, :o1, 1761465600
- tz.transition 2026, 4, :o4, 1775379600
- tz.transition 2026, 10, :o1, 1792915200
- tz.transition 2027, 4, :o4, 1806829200
- tz.transition 2027, 10, :o1, 1824969600
- tz.transition 2028, 4, :o4, 1838278800
- tz.transition 2028, 10, :o1, 1856419200
- tz.transition 2029, 4, :o4, 1869728400
- tz.transition 2029, 10, :o1, 1887868800
- tz.transition 2030, 4, :o4, 1901782800
- tz.transition 2030, 10, :o1, 1919318400
- tz.transition 2031, 4, :o4, 1933232400
- tz.transition 2031, 10, :o1, 1950768000
- tz.transition 2032, 4, :o4, 1964682000
- tz.transition 2032, 10, :o1, 1982822400
- tz.transition 2033, 4, :o4, 1996131600
- tz.transition 2033, 10, :o1, 2014272000
- tz.transition 2034, 4, :o4, 2027581200
- tz.transition 2034, 10, :o1, 2045721600
- tz.transition 2035, 4, :o4, 2059030800
- tz.transition 2035, 10, :o1, 2077171200
- tz.transition 2036, 4, :o4, 2091085200
- tz.transition 2036, 10, :o1, 2108620800
- tz.transition 2037, 4, :o4, 2122534800
- tz.transition 2037, 10, :o1, 2140070400
- tz.transition 2038, 4, :o4, 19724143, 8
- tz.transition 2038, 10, :o1, 14794367, 6
- tz.transition 2039, 4, :o4, 19727055, 8
- tz.transition 2039, 10, :o1, 14796551, 6
- tz.transition 2040, 4, :o4, 19729967, 8
- tz.transition 2040, 10, :o1, 14798735, 6
- tz.transition 2041, 4, :o4, 19732935, 8
- tz.transition 2041, 10, :o1, 14800919, 6
- tz.transition 2042, 4, :o4, 19735847, 8
- tz.transition 2042, 10, :o1, 14803103, 6
- tz.transition 2043, 4, :o4, 19738759, 8
- tz.transition 2043, 10, :o1, 14805287, 6
- tz.transition 2044, 4, :o4, 19741671, 8
- tz.transition 2044, 10, :o1, 14807513, 6
- tz.transition 2045, 4, :o4, 19744583, 8
- tz.transition 2045, 10, :o1, 14809697, 6
- tz.transition 2046, 4, :o4, 19747495, 8
- tz.transition 2046, 10, :o1, 14811881, 6
- tz.transition 2047, 4, :o4, 19750463, 8
- tz.transition 2047, 10, :o1, 14814065, 6
- tz.transition 2048, 4, :o4, 19753375, 8
- tz.transition 2048, 10, :o1, 14816249, 6
- tz.transition 2049, 4, :o4, 19756287, 8
- tz.transition 2049, 10, :o1, 14818475, 6
- tz.transition 2050, 4, :o4, 19759199, 8
- tz.transition 2050, 10, :o1, 14820659, 6
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Denver.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Denver.rb
deleted file mode 100644
index 1c1efb5ff3..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Denver.rb
+++ /dev/null
@@ -1,204 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module Denver
- include TimezoneDefinition
-
- timezone 'America/Denver' do |tz|
- tz.offset :o0, -25196, 0, :LMT
- tz.offset :o1, -25200, 0, :MST
- tz.offset :o2, -25200, 3600, :MDT
- tz.offset :o3, -25200, 3600, :MWT
- tz.offset :o4, -25200, 3600, :MPT
-
- tz.transition 1883, 11, :o1, 57819199, 24
- tz.transition 1918, 3, :o2, 19373471, 8
- tz.transition 1918, 10, :o1, 14531363, 6
- tz.transition 1919, 3, :o2, 19376383, 8
- tz.transition 1919, 10, :o1, 14533547, 6
- tz.transition 1920, 3, :o2, 19379295, 8
- tz.transition 1920, 10, :o1, 14535773, 6
- tz.transition 1921, 3, :o2, 19382207, 8
- tz.transition 1921, 5, :o1, 14536991, 6
- tz.transition 1942, 2, :o3, 19443199, 8
- tz.transition 1945, 8, :o4, 58360379, 24
- tz.transition 1945, 9, :o1, 14590373, 6
- tz.transition 1965, 4, :o2, 19511007, 8
- tz.transition 1965, 10, :o1, 14634389, 6
- tz.transition 1966, 4, :o2, 19513919, 8
- tz.transition 1966, 10, :o1, 14636573, 6
- tz.transition 1967, 4, :o2, 19516887, 8
- tz.transition 1967, 10, :o1, 14638757, 6
- tz.transition 1968, 4, :o2, 19519799, 8
- tz.transition 1968, 10, :o1, 14640941, 6
- tz.transition 1969, 4, :o2, 19522711, 8
- tz.transition 1969, 10, :o1, 14643125, 6
- tz.transition 1970, 4, :o2, 9968400
- tz.transition 1970, 10, :o1, 25689600
- tz.transition 1971, 4, :o2, 41418000
- tz.transition 1971, 10, :o1, 57744000
- tz.transition 1972, 4, :o2, 73472400
- tz.transition 1972, 10, :o1, 89193600
- tz.transition 1973, 4, :o2, 104922000
- tz.transition 1973, 10, :o1, 120643200
- tz.transition 1974, 1, :o2, 126694800
- tz.transition 1974, 10, :o1, 152092800
- tz.transition 1975, 2, :o2, 162378000
- tz.transition 1975, 10, :o1, 183542400
- tz.transition 1976, 4, :o2, 199270800
- tz.transition 1976, 10, :o1, 215596800
- tz.transition 1977, 4, :o2, 230720400
- tz.transition 1977, 10, :o1, 247046400
- tz.transition 1978, 4, :o2, 262774800
- tz.transition 1978, 10, :o1, 278496000
- tz.transition 1979, 4, :o2, 294224400
- tz.transition 1979, 10, :o1, 309945600
- tz.transition 1980, 4, :o2, 325674000
- tz.transition 1980, 10, :o1, 341395200
- tz.transition 1981, 4, :o2, 357123600
- tz.transition 1981, 10, :o1, 372844800
- tz.transition 1982, 4, :o2, 388573200
- tz.transition 1982, 10, :o1, 404899200
- tz.transition 1983, 4, :o2, 420022800
- tz.transition 1983, 10, :o1, 436348800
- tz.transition 1984, 4, :o2, 452077200
- tz.transition 1984, 10, :o1, 467798400
- tz.transition 1985, 4, :o2, 483526800
- tz.transition 1985, 10, :o1, 499248000
- tz.transition 1986, 4, :o2, 514976400
- tz.transition 1986, 10, :o1, 530697600
- tz.transition 1987, 4, :o2, 544611600
- tz.transition 1987, 10, :o1, 562147200
- tz.transition 1988, 4, :o2, 576061200
- tz.transition 1988, 10, :o1, 594201600
- tz.transition 1989, 4, :o2, 607510800
- tz.transition 1989, 10, :o1, 625651200
- tz.transition 1990, 4, :o2, 638960400
- tz.transition 1990, 10, :o1, 657100800
- tz.transition 1991, 4, :o2, 671014800
- tz.transition 1991, 10, :o1, 688550400
- tz.transition 1992, 4, :o2, 702464400
- tz.transition 1992, 10, :o1, 720000000
- tz.transition 1993, 4, :o2, 733914000
- tz.transition 1993, 10, :o1, 752054400
- tz.transition 1994, 4, :o2, 765363600
- tz.transition 1994, 10, :o1, 783504000
- tz.transition 1995, 4, :o2, 796813200
- tz.transition 1995, 10, :o1, 814953600
- tz.transition 1996, 4, :o2, 828867600
- tz.transition 1996, 10, :o1, 846403200
- tz.transition 1997, 4, :o2, 860317200
- tz.transition 1997, 10, :o1, 877852800
- tz.transition 1998, 4, :o2, 891766800
- tz.transition 1998, 10, :o1, 909302400
- tz.transition 1999, 4, :o2, 923216400
- tz.transition 1999, 10, :o1, 941356800
- tz.transition 2000, 4, :o2, 954666000
- tz.transition 2000, 10, :o1, 972806400
- tz.transition 2001, 4, :o2, 986115600
- tz.transition 2001, 10, :o1, 1004256000
- tz.transition 2002, 4, :o2, 1018170000
- tz.transition 2002, 10, :o1, 1035705600
- tz.transition 2003, 4, :o2, 1049619600
- tz.transition 2003, 10, :o1, 1067155200
- tz.transition 2004, 4, :o2, 1081069200
- tz.transition 2004, 10, :o1, 1099209600
- tz.transition 2005, 4, :o2, 1112518800
- tz.transition 2005, 10, :o1, 1130659200
- tz.transition 2006, 4, :o2, 1143968400
- tz.transition 2006, 10, :o1, 1162108800
- tz.transition 2007, 3, :o2, 1173603600
- tz.transition 2007, 11, :o1, 1194163200
- tz.transition 2008, 3, :o2, 1205053200
- tz.transition 2008, 11, :o1, 1225612800
- tz.transition 2009, 3, :o2, 1236502800
- tz.transition 2009, 11, :o1, 1257062400
- tz.transition 2010, 3, :o2, 1268557200
- tz.transition 2010, 11, :o1, 1289116800
- tz.transition 2011, 3, :o2, 1300006800
- tz.transition 2011, 11, :o1, 1320566400
- tz.transition 2012, 3, :o2, 1331456400
- tz.transition 2012, 11, :o1, 1352016000
- tz.transition 2013, 3, :o2, 1362906000
- tz.transition 2013, 11, :o1, 1383465600
- tz.transition 2014, 3, :o2, 1394355600
- tz.transition 2014, 11, :o1, 1414915200
- tz.transition 2015, 3, :o2, 1425805200
- tz.transition 2015, 11, :o1, 1446364800
- tz.transition 2016, 3, :o2, 1457859600
- tz.transition 2016, 11, :o1, 1478419200
- tz.transition 2017, 3, :o2, 1489309200
- tz.transition 2017, 11, :o1, 1509868800
- tz.transition 2018, 3, :o2, 1520758800
- tz.transition 2018, 11, :o1, 1541318400
- tz.transition 2019, 3, :o2, 1552208400
- tz.transition 2019, 11, :o1, 1572768000
- tz.transition 2020, 3, :o2, 1583658000
- tz.transition 2020, 11, :o1, 1604217600
- tz.transition 2021, 3, :o2, 1615712400
- tz.transition 2021, 11, :o1, 1636272000
- tz.transition 2022, 3, :o2, 1647162000
- tz.transition 2022, 11, :o1, 1667721600
- tz.transition 2023, 3, :o2, 1678611600
- tz.transition 2023, 11, :o1, 1699171200
- tz.transition 2024, 3, :o2, 1710061200
- tz.transition 2024, 11, :o1, 1730620800
- tz.transition 2025, 3, :o2, 1741510800
- tz.transition 2025, 11, :o1, 1762070400
- tz.transition 2026, 3, :o2, 1772960400
- tz.transition 2026, 11, :o1, 1793520000
- tz.transition 2027, 3, :o2, 1805014800
- tz.transition 2027, 11, :o1, 1825574400
- tz.transition 2028, 3, :o2, 1836464400
- tz.transition 2028, 11, :o1, 1857024000
- tz.transition 2029, 3, :o2, 1867914000
- tz.transition 2029, 11, :o1, 1888473600
- tz.transition 2030, 3, :o2, 1899363600
- tz.transition 2030, 11, :o1, 1919923200
- tz.transition 2031, 3, :o2, 1930813200
- tz.transition 2031, 11, :o1, 1951372800
- tz.transition 2032, 3, :o2, 1962867600
- tz.transition 2032, 11, :o1, 1983427200
- tz.transition 2033, 3, :o2, 1994317200
- tz.transition 2033, 11, :o1, 2014876800
- tz.transition 2034, 3, :o2, 2025766800
- tz.transition 2034, 11, :o1, 2046326400
- tz.transition 2035, 3, :o2, 2057216400
- tz.transition 2035, 11, :o1, 2077776000
- tz.transition 2036, 3, :o2, 2088666000
- tz.transition 2036, 11, :o1, 2109225600
- tz.transition 2037, 3, :o2, 2120115600
- tz.transition 2037, 11, :o1, 2140675200
- tz.transition 2038, 3, :o2, 19723975, 8
- tz.transition 2038, 11, :o1, 14794409, 6
- tz.transition 2039, 3, :o2, 19726887, 8
- tz.transition 2039, 11, :o1, 14796593, 6
- tz.transition 2040, 3, :o2, 19729799, 8
- tz.transition 2040, 11, :o1, 14798777, 6
- tz.transition 2041, 3, :o2, 19732711, 8
- tz.transition 2041, 11, :o1, 14800961, 6
- tz.transition 2042, 3, :o2, 19735623, 8
- tz.transition 2042, 11, :o1, 14803145, 6
- tz.transition 2043, 3, :o2, 19738535, 8
- tz.transition 2043, 11, :o1, 14805329, 6
- tz.transition 2044, 3, :o2, 19741503, 8
- tz.transition 2044, 11, :o1, 14807555, 6
- tz.transition 2045, 3, :o2, 19744415, 8
- tz.transition 2045, 11, :o1, 14809739, 6
- tz.transition 2046, 3, :o2, 19747327, 8
- tz.transition 2046, 11, :o1, 14811923, 6
- tz.transition 2047, 3, :o2, 19750239, 8
- tz.transition 2047, 11, :o1, 14814107, 6
- tz.transition 2048, 3, :o2, 19753151, 8
- tz.transition 2048, 11, :o1, 14816291, 6
- tz.transition 2049, 3, :o2, 19756119, 8
- tz.transition 2049, 11, :o1, 14818517, 6
- tz.transition 2050, 3, :o2, 19759031, 8
- tz.transition 2050, 11, :o1, 14820701, 6
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Godthab.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Godthab.rb
deleted file mode 100644
index 1e05518b0d..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Godthab.rb
+++ /dev/null
@@ -1,161 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module Godthab
- include TimezoneDefinition
-
- timezone 'America/Godthab' do |tz|
- tz.offset :o0, -12416, 0, :LMT
- tz.offset :o1, -10800, 0, :WGT
- tz.offset :o2, -10800, 3600, :WGST
-
- tz.transition 1916, 7, :o1, 3268448069, 1350
- tz.transition 1980, 4, :o2, 323845200
- tz.transition 1980, 9, :o1, 338950800
- tz.transition 1981, 3, :o2, 354675600
- tz.transition 1981, 9, :o1, 370400400
- tz.transition 1982, 3, :o2, 386125200
- tz.transition 1982, 9, :o1, 401850000
- tz.transition 1983, 3, :o2, 417574800
- tz.transition 1983, 9, :o1, 433299600
- tz.transition 1984, 3, :o2, 449024400
- tz.transition 1984, 9, :o1, 465354000
- tz.transition 1985, 3, :o2, 481078800
- tz.transition 1985, 9, :o1, 496803600
- tz.transition 1986, 3, :o2, 512528400
- tz.transition 1986, 9, :o1, 528253200
- tz.transition 1987, 3, :o2, 543978000
- tz.transition 1987, 9, :o1, 559702800
- tz.transition 1988, 3, :o2, 575427600
- tz.transition 1988, 9, :o1, 591152400
- tz.transition 1989, 3, :o2, 606877200
- tz.transition 1989, 9, :o1, 622602000
- tz.transition 1990, 3, :o2, 638326800
- tz.transition 1990, 9, :o1, 654656400
- tz.transition 1991, 3, :o2, 670381200
- tz.transition 1991, 9, :o1, 686106000
- tz.transition 1992, 3, :o2, 701830800
- tz.transition 1992, 9, :o1, 717555600
- tz.transition 1993, 3, :o2, 733280400
- tz.transition 1993, 9, :o1, 749005200
- tz.transition 1994, 3, :o2, 764730000
- tz.transition 1994, 9, :o1, 780454800
- tz.transition 1995, 3, :o2, 796179600
- tz.transition 1995, 9, :o1, 811904400
- tz.transition 1996, 3, :o2, 828234000
- tz.transition 1996, 10, :o1, 846378000
- tz.transition 1997, 3, :o2, 859683600
- tz.transition 1997, 10, :o1, 877827600
- tz.transition 1998, 3, :o2, 891133200
- tz.transition 1998, 10, :o1, 909277200
- tz.transition 1999, 3, :o2, 922582800
- tz.transition 1999, 10, :o1, 941331600
- tz.transition 2000, 3, :o2, 954032400
- tz.transition 2000, 10, :o1, 972781200
- tz.transition 2001, 3, :o2, 985482000
- tz.transition 2001, 10, :o1, 1004230800
- tz.transition 2002, 3, :o2, 1017536400
- tz.transition 2002, 10, :o1, 1035680400
- tz.transition 2003, 3, :o2, 1048986000
- tz.transition 2003, 10, :o1, 1067130000
- tz.transition 2004, 3, :o2, 1080435600
- tz.transition 2004, 10, :o1, 1099184400
- tz.transition 2005, 3, :o2, 1111885200
- tz.transition 2005, 10, :o1, 1130634000
- tz.transition 2006, 3, :o2, 1143334800
- tz.transition 2006, 10, :o1, 1162083600
- tz.transition 2007, 3, :o2, 1174784400
- tz.transition 2007, 10, :o1, 1193533200
- tz.transition 2008, 3, :o2, 1206838800
- tz.transition 2008, 10, :o1, 1224982800
- tz.transition 2009, 3, :o2, 1238288400
- tz.transition 2009, 10, :o1, 1256432400
- tz.transition 2010, 3, :o2, 1269738000
- tz.transition 2010, 10, :o1, 1288486800
- tz.transition 2011, 3, :o2, 1301187600
- tz.transition 2011, 10, :o1, 1319936400
- tz.transition 2012, 3, :o2, 1332637200
- tz.transition 2012, 10, :o1, 1351386000
- tz.transition 2013, 3, :o2, 1364691600
- tz.transition 2013, 10, :o1, 1382835600
- tz.transition 2014, 3, :o2, 1396141200
- tz.transition 2014, 10, :o1, 1414285200
- tz.transition 2015, 3, :o2, 1427590800
- tz.transition 2015, 10, :o1, 1445734800
- tz.transition 2016, 3, :o2, 1459040400
- tz.transition 2016, 10, :o1, 1477789200
- tz.transition 2017, 3, :o2, 1490490000
- tz.transition 2017, 10, :o1, 1509238800
- tz.transition 2018, 3, :o2, 1521939600
- tz.transition 2018, 10, :o1, 1540688400
- tz.transition 2019, 3, :o2, 1553994000
- tz.transition 2019, 10, :o1, 1572138000
- tz.transition 2020, 3, :o2, 1585443600
- tz.transition 2020, 10, :o1, 1603587600
- tz.transition 2021, 3, :o2, 1616893200
- tz.transition 2021, 10, :o1, 1635642000
- tz.transition 2022, 3, :o2, 1648342800
- tz.transition 2022, 10, :o1, 1667091600
- tz.transition 2023, 3, :o2, 1679792400
- tz.transition 2023, 10, :o1, 1698541200
- tz.transition 2024, 3, :o2, 1711846800
- tz.transition 2024, 10, :o1, 1729990800
- tz.transition 2025, 3, :o2, 1743296400
- tz.transition 2025, 10, :o1, 1761440400
- tz.transition 2026, 3, :o2, 1774746000
- tz.transition 2026, 10, :o1, 1792890000
- tz.transition 2027, 3, :o2, 1806195600
- tz.transition 2027, 10, :o1, 1824944400
- tz.transition 2028, 3, :o2, 1837645200
- tz.transition 2028, 10, :o1, 1856394000
- tz.transition 2029, 3, :o2, 1869094800
- tz.transition 2029, 10, :o1, 1887843600
- tz.transition 2030, 3, :o2, 1901149200
- tz.transition 2030, 10, :o1, 1919293200
- tz.transition 2031, 3, :o2, 1932598800
- tz.transition 2031, 10, :o1, 1950742800
- tz.transition 2032, 3, :o2, 1964048400
- tz.transition 2032, 10, :o1, 1982797200
- tz.transition 2033, 3, :o2, 1995498000
- tz.transition 2033, 10, :o1, 2014246800
- tz.transition 2034, 3, :o2, 2026947600
- tz.transition 2034, 10, :o1, 2045696400
- tz.transition 2035, 3, :o2, 2058397200
- tz.transition 2035, 10, :o1, 2077146000
- tz.transition 2036, 3, :o2, 2090451600
- tz.transition 2036, 10, :o1, 2108595600
- tz.transition 2037, 3, :o2, 2121901200
- tz.transition 2037, 10, :o1, 2140045200
- tz.transition 2038, 3, :o2, 59172253, 24
- tz.transition 2038, 10, :o1, 59177461, 24
- tz.transition 2039, 3, :o2, 59180989, 24
- tz.transition 2039, 10, :o1, 59186197, 24
- tz.transition 2040, 3, :o2, 59189725, 24
- tz.transition 2040, 10, :o1, 59194933, 24
- tz.transition 2041, 3, :o2, 59198629, 24
- tz.transition 2041, 10, :o1, 59203669, 24
- tz.transition 2042, 3, :o2, 59207365, 24
- tz.transition 2042, 10, :o1, 59212405, 24
- tz.transition 2043, 3, :o2, 59216101, 24
- tz.transition 2043, 10, :o1, 59221141, 24
- tz.transition 2044, 3, :o2, 59224837, 24
- tz.transition 2044, 10, :o1, 59230045, 24
- tz.transition 2045, 3, :o2, 59233573, 24
- tz.transition 2045, 10, :o1, 59238781, 24
- tz.transition 2046, 3, :o2, 59242309, 24
- tz.transition 2046, 10, :o1, 59247517, 24
- tz.transition 2047, 3, :o2, 59251213, 24
- tz.transition 2047, 10, :o1, 59256253, 24
- tz.transition 2048, 3, :o2, 59259949, 24
- tz.transition 2048, 10, :o1, 59264989, 24
- tz.transition 2049, 3, :o2, 59268685, 24
- tz.transition 2049, 10, :o1, 59273893, 24
- tz.transition 2050, 3, :o2, 59277421, 24
- tz.transition 2050, 10, :o1, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Guatemala.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Guatemala.rb
deleted file mode 100644
index a2bf73401c..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Guatemala.rb
+++ /dev/null
@@ -1,27 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module Guatemala
- include TimezoneDefinition
-
- timezone 'America/Guatemala' do |tz|
- tz.offset :o0, -21724, 0, :LMT
- tz.offset :o1, -21600, 0, :CST
- tz.offset :o2, -21600, 3600, :CDT
-
- tz.transition 1918, 10, :o1, 52312429831, 21600
- tz.transition 1973, 11, :o2, 123055200
- tz.transition 1974, 2, :o1, 130914000
- tz.transition 1983, 5, :o2, 422344800
- tz.transition 1983, 9, :o1, 433054800
- tz.transition 1991, 3, :o2, 669708000
- tz.transition 1991, 9, :o1, 684219600
- tz.transition 2006, 4, :o2, 1146376800
- tz.transition 2006, 10, :o1, 1159678800
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Halifax.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Halifax.rb
deleted file mode 100644
index d25ae775b3..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Halifax.rb
+++ /dev/null
@@ -1,274 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module Halifax
- include TimezoneDefinition
-
- timezone 'America/Halifax' do |tz|
- tz.offset :o0, -15264, 0, :LMT
- tz.offset :o1, -14400, 0, :AST
- tz.offset :o2, -14400, 3600, :ADT
- tz.offset :o3, -14400, 3600, :AWT
- tz.offset :o4, -14400, 3600, :APT
-
- tz.transition 1902, 6, :o1, 724774703, 300
- tz.transition 1916, 4, :o2, 7262864, 3
- tz.transition 1916, 10, :o1, 19369101, 8
- tz.transition 1918, 4, :o2, 9686791, 4
- tz.transition 1918, 10, :o1, 58125545, 24
- tz.transition 1920, 5, :o2, 7267361, 3
- tz.transition 1920, 8, :o1, 19380525, 8
- tz.transition 1921, 5, :o2, 7268447, 3
- tz.transition 1921, 9, :o1, 19383501, 8
- tz.transition 1922, 4, :o2, 7269524, 3
- tz.transition 1922, 9, :o1, 19386421, 8
- tz.transition 1923, 5, :o2, 7270637, 3
- tz.transition 1923, 9, :o1, 19389333, 8
- tz.transition 1924, 5, :o2, 7271729, 3
- tz.transition 1924, 9, :o1, 19392349, 8
- tz.transition 1925, 5, :o2, 7272821, 3
- tz.transition 1925, 9, :o1, 19395373, 8
- tz.transition 1926, 5, :o2, 7273955, 3
- tz.transition 1926, 9, :o1, 19398173, 8
- tz.transition 1927, 5, :o2, 7275005, 3
- tz.transition 1927, 9, :o1, 19401197, 8
- tz.transition 1928, 5, :o2, 7276139, 3
- tz.transition 1928, 9, :o1, 19403989, 8
- tz.transition 1929, 5, :o2, 7277231, 3
- tz.transition 1929, 9, :o1, 19406861, 8
- tz.transition 1930, 5, :o2, 7278323, 3
- tz.transition 1930, 9, :o1, 19409877, 8
- tz.transition 1931, 5, :o2, 7279415, 3
- tz.transition 1931, 9, :o1, 19412901, 8
- tz.transition 1932, 5, :o2, 7280486, 3
- tz.transition 1932, 9, :o1, 19415813, 8
- tz.transition 1933, 4, :o2, 7281578, 3
- tz.transition 1933, 10, :o1, 19418781, 8
- tz.transition 1934, 5, :o2, 7282733, 3
- tz.transition 1934, 9, :o1, 19421573, 8
- tz.transition 1935, 6, :o2, 7283867, 3
- tz.transition 1935, 9, :o1, 19424605, 8
- tz.transition 1936, 6, :o2, 7284962, 3
- tz.transition 1936, 9, :o1, 19427405, 8
- tz.transition 1937, 5, :o2, 7285967, 3
- tz.transition 1937, 9, :o1, 19430429, 8
- tz.transition 1938, 5, :o2, 7287059, 3
- tz.transition 1938, 9, :o1, 19433341, 8
- tz.transition 1939, 5, :o2, 7288235, 3
- tz.transition 1939, 9, :o1, 19436253, 8
- tz.transition 1940, 5, :o2, 7289264, 3
- tz.transition 1940, 9, :o1, 19439221, 8
- tz.transition 1941, 5, :o2, 7290356, 3
- tz.transition 1941, 9, :o1, 19442133, 8
- tz.transition 1942, 2, :o3, 9721599, 4
- tz.transition 1945, 8, :o4, 58360379, 24
- tz.transition 1945, 9, :o1, 58361489, 24
- tz.transition 1946, 4, :o2, 9727755, 4
- tz.transition 1946, 9, :o1, 58370225, 24
- tz.transition 1947, 4, :o2, 9729211, 4
- tz.transition 1947, 9, :o1, 58378961, 24
- tz.transition 1948, 4, :o2, 9730667, 4
- tz.transition 1948, 9, :o1, 58387697, 24
- tz.transition 1949, 4, :o2, 9732123, 4
- tz.transition 1949, 9, :o1, 58396433, 24
- tz.transition 1951, 4, :o2, 9735063, 4
- tz.transition 1951, 9, :o1, 58414073, 24
- tz.transition 1952, 4, :o2, 9736519, 4
- tz.transition 1952, 9, :o1, 58422809, 24
- tz.transition 1953, 4, :o2, 9737975, 4
- tz.transition 1953, 9, :o1, 58431545, 24
- tz.transition 1954, 4, :o2, 9739431, 4
- tz.transition 1954, 9, :o1, 58440281, 24
- tz.transition 1956, 4, :o2, 9742371, 4
- tz.transition 1956, 9, :o1, 58457921, 24
- tz.transition 1957, 4, :o2, 9743827, 4
- tz.transition 1957, 9, :o1, 58466657, 24
- tz.transition 1958, 4, :o2, 9745283, 4
- tz.transition 1958, 9, :o1, 58475393, 24
- tz.transition 1959, 4, :o2, 9746739, 4
- tz.transition 1959, 9, :o1, 58484129, 24
- tz.transition 1962, 4, :o2, 9751135, 4
- tz.transition 1962, 10, :o1, 58511177, 24
- tz.transition 1963, 4, :o2, 9752591, 4
- tz.transition 1963, 10, :o1, 58519913, 24
- tz.transition 1964, 4, :o2, 9754047, 4
- tz.transition 1964, 10, :o1, 58528649, 24
- tz.transition 1965, 4, :o2, 9755503, 4
- tz.transition 1965, 10, :o1, 58537553, 24
- tz.transition 1966, 4, :o2, 9756959, 4
- tz.transition 1966, 10, :o1, 58546289, 24
- tz.transition 1967, 4, :o2, 9758443, 4
- tz.transition 1967, 10, :o1, 58555025, 24
- tz.transition 1968, 4, :o2, 9759899, 4
- tz.transition 1968, 10, :o1, 58563761, 24
- tz.transition 1969, 4, :o2, 9761355, 4
- tz.transition 1969, 10, :o1, 58572497, 24
- tz.transition 1970, 4, :o2, 9957600
- tz.transition 1970, 10, :o1, 25678800
- tz.transition 1971, 4, :o2, 41407200
- tz.transition 1971, 10, :o1, 57733200
- tz.transition 1972, 4, :o2, 73461600
- tz.transition 1972, 10, :o1, 89182800
- tz.transition 1973, 4, :o2, 104911200
- tz.transition 1973, 10, :o1, 120632400
- tz.transition 1974, 4, :o2, 136360800
- tz.transition 1974, 10, :o1, 152082000
- tz.transition 1975, 4, :o2, 167810400
- tz.transition 1975, 10, :o1, 183531600
- tz.transition 1976, 4, :o2, 199260000
- tz.transition 1976, 10, :o1, 215586000
- tz.transition 1977, 4, :o2, 230709600
- tz.transition 1977, 10, :o1, 247035600
- tz.transition 1978, 4, :o2, 262764000
- tz.transition 1978, 10, :o1, 278485200
- tz.transition 1979, 4, :o2, 294213600
- tz.transition 1979, 10, :o1, 309934800
- tz.transition 1980, 4, :o2, 325663200
- tz.transition 1980, 10, :o1, 341384400
- tz.transition 1981, 4, :o2, 357112800
- tz.transition 1981, 10, :o1, 372834000
- tz.transition 1982, 4, :o2, 388562400
- tz.transition 1982, 10, :o1, 404888400
- tz.transition 1983, 4, :o2, 420012000
- tz.transition 1983, 10, :o1, 436338000
- tz.transition 1984, 4, :o2, 452066400
- tz.transition 1984, 10, :o1, 467787600
- tz.transition 1985, 4, :o2, 483516000
- tz.transition 1985, 10, :o1, 499237200
- tz.transition 1986, 4, :o2, 514965600
- tz.transition 1986, 10, :o1, 530686800
- tz.transition 1987, 4, :o2, 544600800
- tz.transition 1987, 10, :o1, 562136400
- tz.transition 1988, 4, :o2, 576050400
- tz.transition 1988, 10, :o1, 594190800
- tz.transition 1989, 4, :o2, 607500000
- tz.transition 1989, 10, :o1, 625640400
- tz.transition 1990, 4, :o2, 638949600
- tz.transition 1990, 10, :o1, 657090000
- tz.transition 1991, 4, :o2, 671004000
- tz.transition 1991, 10, :o1, 688539600
- tz.transition 1992, 4, :o2, 702453600
- tz.transition 1992, 10, :o1, 719989200
- tz.transition 1993, 4, :o2, 733903200
- tz.transition 1993, 10, :o1, 752043600
- tz.transition 1994, 4, :o2, 765352800
- tz.transition 1994, 10, :o1, 783493200
- tz.transition 1995, 4, :o2, 796802400
- tz.transition 1995, 10, :o1, 814942800
- tz.transition 1996, 4, :o2, 828856800
- tz.transition 1996, 10, :o1, 846392400
- tz.transition 1997, 4, :o2, 860306400
- tz.transition 1997, 10, :o1, 877842000
- tz.transition 1998, 4, :o2, 891756000
- tz.transition 1998, 10, :o1, 909291600
- tz.transition 1999, 4, :o2, 923205600
- tz.transition 1999, 10, :o1, 941346000
- tz.transition 2000, 4, :o2, 954655200
- tz.transition 2000, 10, :o1, 972795600
- tz.transition 2001, 4, :o2, 986104800
- tz.transition 2001, 10, :o1, 1004245200
- tz.transition 2002, 4, :o2, 1018159200
- tz.transition 2002, 10, :o1, 1035694800
- tz.transition 2003, 4, :o2, 1049608800
- tz.transition 2003, 10, :o1, 1067144400
- tz.transition 2004, 4, :o2, 1081058400
- tz.transition 2004, 10, :o1, 1099198800
- tz.transition 2005, 4, :o2, 1112508000
- tz.transition 2005, 10, :o1, 1130648400
- tz.transition 2006, 4, :o2, 1143957600
- tz.transition 2006, 10, :o1, 1162098000
- tz.transition 2007, 3, :o2, 1173592800
- tz.transition 2007, 11, :o1, 1194152400
- tz.transition 2008, 3, :o2, 1205042400
- tz.transition 2008, 11, :o1, 1225602000
- tz.transition 2009, 3, :o2, 1236492000
- tz.transition 2009, 11, :o1, 1257051600
- tz.transition 2010, 3, :o2, 1268546400
- tz.transition 2010, 11, :o1, 1289106000
- tz.transition 2011, 3, :o2, 1299996000
- tz.transition 2011, 11, :o1, 1320555600
- tz.transition 2012, 3, :o2, 1331445600
- tz.transition 2012, 11, :o1, 1352005200
- tz.transition 2013, 3, :o2, 1362895200
- tz.transition 2013, 11, :o1, 1383454800
- tz.transition 2014, 3, :o2, 1394344800
- tz.transition 2014, 11, :o1, 1414904400
- tz.transition 2015, 3, :o2, 1425794400
- tz.transition 2015, 11, :o1, 1446354000
- tz.transition 2016, 3, :o2, 1457848800
- tz.transition 2016, 11, :o1, 1478408400
- tz.transition 2017, 3, :o2, 1489298400
- tz.transition 2017, 11, :o1, 1509858000
- tz.transition 2018, 3, :o2, 1520748000
- tz.transition 2018, 11, :o1, 1541307600
- tz.transition 2019, 3, :o2, 1552197600
- tz.transition 2019, 11, :o1, 1572757200
- tz.transition 2020, 3, :o2, 1583647200
- tz.transition 2020, 11, :o1, 1604206800
- tz.transition 2021, 3, :o2, 1615701600
- tz.transition 2021, 11, :o1, 1636261200
- tz.transition 2022, 3, :o2, 1647151200
- tz.transition 2022, 11, :o1, 1667710800
- tz.transition 2023, 3, :o2, 1678600800
- tz.transition 2023, 11, :o1, 1699160400
- tz.transition 2024, 3, :o2, 1710050400
- tz.transition 2024, 11, :o1, 1730610000
- tz.transition 2025, 3, :o2, 1741500000
- tz.transition 2025, 11, :o1, 1762059600
- tz.transition 2026, 3, :o2, 1772949600
- tz.transition 2026, 11, :o1, 1793509200
- tz.transition 2027, 3, :o2, 1805004000
- tz.transition 2027, 11, :o1, 1825563600
- tz.transition 2028, 3, :o2, 1836453600
- tz.transition 2028, 11, :o1, 1857013200
- tz.transition 2029, 3, :o2, 1867903200
- tz.transition 2029, 11, :o1, 1888462800
- tz.transition 2030, 3, :o2, 1899352800
- tz.transition 2030, 11, :o1, 1919912400
- tz.transition 2031, 3, :o2, 1930802400
- tz.transition 2031, 11, :o1, 1951362000
- tz.transition 2032, 3, :o2, 1962856800
- tz.transition 2032, 11, :o1, 1983416400
- tz.transition 2033, 3, :o2, 1994306400
- tz.transition 2033, 11, :o1, 2014866000
- tz.transition 2034, 3, :o2, 2025756000
- tz.transition 2034, 11, :o1, 2046315600
- tz.transition 2035, 3, :o2, 2057205600
- tz.transition 2035, 11, :o1, 2077765200
- tz.transition 2036, 3, :o2, 2088655200
- tz.transition 2036, 11, :o1, 2109214800
- tz.transition 2037, 3, :o2, 2120104800
- tz.transition 2037, 11, :o1, 2140664400
- tz.transition 2038, 3, :o2, 9861987, 4
- tz.transition 2038, 11, :o1, 59177633, 24
- tz.transition 2039, 3, :o2, 9863443, 4
- tz.transition 2039, 11, :o1, 59186369, 24
- tz.transition 2040, 3, :o2, 9864899, 4
- tz.transition 2040, 11, :o1, 59195105, 24
- tz.transition 2041, 3, :o2, 9866355, 4
- tz.transition 2041, 11, :o1, 59203841, 24
- tz.transition 2042, 3, :o2, 9867811, 4
- tz.transition 2042, 11, :o1, 59212577, 24
- tz.transition 2043, 3, :o2, 9869267, 4
- tz.transition 2043, 11, :o1, 59221313, 24
- tz.transition 2044, 3, :o2, 9870751, 4
- tz.transition 2044, 11, :o1, 59230217, 24
- tz.transition 2045, 3, :o2, 9872207, 4
- tz.transition 2045, 11, :o1, 59238953, 24
- tz.transition 2046, 3, :o2, 9873663, 4
- tz.transition 2046, 11, :o1, 59247689, 24
- tz.transition 2047, 3, :o2, 9875119, 4
- tz.transition 2047, 11, :o1, 59256425, 24
- tz.transition 2048, 3, :o2, 9876575, 4
- tz.transition 2048, 11, :o1, 59265161, 24
- tz.transition 2049, 3, :o2, 9878059, 4
- tz.transition 2049, 11, :o1, 59274065, 24
- tz.transition 2050, 3, :o2, 9879515, 4
- tz.transition 2050, 11, :o1, 59282801, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Indiana/Indianapolis.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Indiana/Indianapolis.rb
deleted file mode 100644
index f1430f6c24..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Indiana/Indianapolis.rb
+++ /dev/null
@@ -1,149 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module Indiana
- module Indianapolis
- include TimezoneDefinition
-
- timezone 'America/Indiana/Indianapolis' do |tz|
- tz.offset :o0, -20678, 0, :LMT
- tz.offset :o1, -21600, 0, :CST
- tz.offset :o2, -21600, 3600, :CDT
- tz.offset :o3, -21600, 3600, :CWT
- tz.offset :o4, -21600, 3600, :CPT
- tz.offset :o5, -18000, 0, :EST
- tz.offset :o6, -18000, 3600, :EDT
-
- tz.transition 1883, 11, :o1, 9636533, 4
- tz.transition 1918, 3, :o2, 14530103, 6
- tz.transition 1918, 10, :o1, 58125451, 24
- tz.transition 1919, 3, :o2, 14532287, 6
- tz.transition 1919, 10, :o1, 58134187, 24
- tz.transition 1941, 6, :o2, 14581007, 6
- tz.transition 1941, 9, :o1, 58326379, 24
- tz.transition 1942, 2, :o3, 14582399, 6
- tz.transition 1945, 8, :o4, 58360379, 24
- tz.transition 1945, 9, :o1, 58361491, 24
- tz.transition 1946, 4, :o2, 14591633, 6
- tz.transition 1946, 9, :o1, 58370227, 24
- tz.transition 1947, 4, :o2, 14593817, 6
- tz.transition 1947, 9, :o1, 58378963, 24
- tz.transition 1948, 4, :o2, 14596001, 6
- tz.transition 1948, 9, :o1, 58387699, 24
- tz.transition 1949, 4, :o2, 14598185, 6
- tz.transition 1949, 9, :o1, 58396435, 24
- tz.transition 1950, 4, :o2, 14600411, 6
- tz.transition 1950, 9, :o1, 58405171, 24
- tz.transition 1951, 4, :o2, 14602595, 6
- tz.transition 1951, 9, :o1, 58414075, 24
- tz.transition 1952, 4, :o2, 14604779, 6
- tz.transition 1952, 9, :o1, 58422811, 24
- tz.transition 1953, 4, :o2, 14606963, 6
- tz.transition 1953, 9, :o1, 58431547, 24
- tz.transition 1954, 4, :o2, 14609147, 6
- tz.transition 1954, 9, :o1, 58440283, 24
- tz.transition 1955, 4, :o5, 14611331, 6
- tz.transition 1957, 9, :o1, 58466659, 24
- tz.transition 1958, 4, :o5, 14617925, 6
- tz.transition 1969, 4, :o6, 58568131, 24
- tz.transition 1969, 10, :o5, 9762083, 4
- tz.transition 1970, 4, :o6, 9961200
- tz.transition 1970, 10, :o5, 25682400
- tz.transition 2006, 4, :o6, 1143961200
- tz.transition 2006, 10, :o5, 1162101600
- tz.transition 2007, 3, :o6, 1173596400
- tz.transition 2007, 11, :o5, 1194156000
- tz.transition 2008, 3, :o6, 1205046000
- tz.transition 2008, 11, :o5, 1225605600
- tz.transition 2009, 3, :o6, 1236495600
- tz.transition 2009, 11, :o5, 1257055200
- tz.transition 2010, 3, :o6, 1268550000
- tz.transition 2010, 11, :o5, 1289109600
- tz.transition 2011, 3, :o6, 1299999600
- tz.transition 2011, 11, :o5, 1320559200
- tz.transition 2012, 3, :o6, 1331449200
- tz.transition 2012, 11, :o5, 1352008800
- tz.transition 2013, 3, :o6, 1362898800
- tz.transition 2013, 11, :o5, 1383458400
- tz.transition 2014, 3, :o6, 1394348400
- tz.transition 2014, 11, :o5, 1414908000
- tz.transition 2015, 3, :o6, 1425798000
- tz.transition 2015, 11, :o5, 1446357600
- tz.transition 2016, 3, :o6, 1457852400
- tz.transition 2016, 11, :o5, 1478412000
- tz.transition 2017, 3, :o6, 1489302000
- tz.transition 2017, 11, :o5, 1509861600
- tz.transition 2018, 3, :o6, 1520751600
- tz.transition 2018, 11, :o5, 1541311200
- tz.transition 2019, 3, :o6, 1552201200
- tz.transition 2019, 11, :o5, 1572760800
- tz.transition 2020, 3, :o6, 1583650800
- tz.transition 2020, 11, :o5, 1604210400
- tz.transition 2021, 3, :o6, 1615705200
- tz.transition 2021, 11, :o5, 1636264800
- tz.transition 2022, 3, :o6, 1647154800
- tz.transition 2022, 11, :o5, 1667714400
- tz.transition 2023, 3, :o6, 1678604400
- tz.transition 2023, 11, :o5, 1699164000
- tz.transition 2024, 3, :o6, 1710054000
- tz.transition 2024, 11, :o5, 1730613600
- tz.transition 2025, 3, :o6, 1741503600
- tz.transition 2025, 11, :o5, 1762063200
- tz.transition 2026, 3, :o6, 1772953200
- tz.transition 2026, 11, :o5, 1793512800
- tz.transition 2027, 3, :o6, 1805007600
- tz.transition 2027, 11, :o5, 1825567200
- tz.transition 2028, 3, :o6, 1836457200
- tz.transition 2028, 11, :o5, 1857016800
- tz.transition 2029, 3, :o6, 1867906800
- tz.transition 2029, 11, :o5, 1888466400
- tz.transition 2030, 3, :o6, 1899356400
- tz.transition 2030, 11, :o5, 1919916000
- tz.transition 2031, 3, :o6, 1930806000
- tz.transition 2031, 11, :o5, 1951365600
- tz.transition 2032, 3, :o6, 1962860400
- tz.transition 2032, 11, :o5, 1983420000
- tz.transition 2033, 3, :o6, 1994310000
- tz.transition 2033, 11, :o5, 2014869600
- tz.transition 2034, 3, :o6, 2025759600
- tz.transition 2034, 11, :o5, 2046319200
- tz.transition 2035, 3, :o6, 2057209200
- tz.transition 2035, 11, :o5, 2077768800
- tz.transition 2036, 3, :o6, 2088658800
- tz.transition 2036, 11, :o5, 2109218400
- tz.transition 2037, 3, :o6, 2120108400
- tz.transition 2037, 11, :o5, 2140668000
- tz.transition 2038, 3, :o6, 59171923, 24
- tz.transition 2038, 11, :o5, 9862939, 4
- tz.transition 2039, 3, :o6, 59180659, 24
- tz.transition 2039, 11, :o5, 9864395, 4
- tz.transition 2040, 3, :o6, 59189395, 24
- tz.transition 2040, 11, :o5, 9865851, 4
- tz.transition 2041, 3, :o6, 59198131, 24
- tz.transition 2041, 11, :o5, 9867307, 4
- tz.transition 2042, 3, :o6, 59206867, 24
- tz.transition 2042, 11, :o5, 9868763, 4
- tz.transition 2043, 3, :o6, 59215603, 24
- tz.transition 2043, 11, :o5, 9870219, 4
- tz.transition 2044, 3, :o6, 59224507, 24
- tz.transition 2044, 11, :o5, 9871703, 4
- tz.transition 2045, 3, :o6, 59233243, 24
- tz.transition 2045, 11, :o5, 9873159, 4
- tz.transition 2046, 3, :o6, 59241979, 24
- tz.transition 2046, 11, :o5, 9874615, 4
- tz.transition 2047, 3, :o6, 59250715, 24
- tz.transition 2047, 11, :o5, 9876071, 4
- tz.transition 2048, 3, :o6, 59259451, 24
- tz.transition 2048, 11, :o5, 9877527, 4
- tz.transition 2049, 3, :o6, 59268355, 24
- tz.transition 2049, 11, :o5, 9879011, 4
- tz.transition 2050, 3, :o6, 59277091, 24
- tz.transition 2050, 11, :o5, 9880467, 4
- end
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Juneau.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Juneau.rb
deleted file mode 100644
index f646f3f54a..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Juneau.rb
+++ /dev/null
@@ -1,194 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module Juneau
- include TimezoneDefinition
-
- timezone 'America/Juneau' do |tz|
- tz.offset :o0, 54139, 0, :LMT
- tz.offset :o1, -32261, 0, :LMT
- tz.offset :o2, -28800, 0, :PST
- tz.offset :o3, -28800, 3600, :PWT
- tz.offset :o4, -28800, 3600, :PPT
- tz.offset :o5, -28800, 3600, :PDT
- tz.offset :o6, -32400, 0, :YST
- tz.offset :o7, -32400, 0, :AKST
- tz.offset :o8, -32400, 3600, :AKDT
-
- tz.transition 1867, 10, :o1, 207641393861, 86400
- tz.transition 1900, 8, :o2, 208677805061, 86400
- tz.transition 1942, 2, :o3, 29164799, 12
- tz.transition 1945, 8, :o4, 58360379, 24
- tz.transition 1945, 9, :o2, 19453831, 8
- tz.transition 1969, 4, :o5, 29284067, 12
- tz.transition 1969, 10, :o2, 19524167, 8
- tz.transition 1970, 4, :o5, 9972000
- tz.transition 1970, 10, :o2, 25693200
- tz.transition 1971, 4, :o5, 41421600
- tz.transition 1971, 10, :o2, 57747600
- tz.transition 1972, 4, :o5, 73476000
- tz.transition 1972, 10, :o2, 89197200
- tz.transition 1973, 4, :o5, 104925600
- tz.transition 1973, 10, :o2, 120646800
- tz.transition 1974, 1, :o5, 126698400
- tz.transition 1974, 10, :o2, 152096400
- tz.transition 1975, 2, :o5, 162381600
- tz.transition 1975, 10, :o2, 183546000
- tz.transition 1976, 4, :o5, 199274400
- tz.transition 1976, 10, :o2, 215600400
- tz.transition 1977, 4, :o5, 230724000
- tz.transition 1977, 10, :o2, 247050000
- tz.transition 1978, 4, :o5, 262778400
- tz.transition 1978, 10, :o2, 278499600
- tz.transition 1979, 4, :o5, 294228000
- tz.transition 1979, 10, :o2, 309949200
- tz.transition 1980, 4, :o5, 325677600
- tz.transition 1980, 10, :o2, 341398800
- tz.transition 1981, 4, :o5, 357127200
- tz.transition 1981, 10, :o2, 372848400
- tz.transition 1982, 4, :o5, 388576800
- tz.transition 1982, 10, :o2, 404902800
- tz.transition 1983, 4, :o5, 420026400
- tz.transition 1983, 10, :o6, 436352400
- tz.transition 1983, 11, :o7, 439030800
- tz.transition 1984, 4, :o8, 452084400
- tz.transition 1984, 10, :o7, 467805600
- tz.transition 1985, 4, :o8, 483534000
- tz.transition 1985, 10, :o7, 499255200
- tz.transition 1986, 4, :o8, 514983600
- tz.transition 1986, 10, :o7, 530704800
- tz.transition 1987, 4, :o8, 544618800
- tz.transition 1987, 10, :o7, 562154400
- tz.transition 1988, 4, :o8, 576068400
- tz.transition 1988, 10, :o7, 594208800
- tz.transition 1989, 4, :o8, 607518000
- tz.transition 1989, 10, :o7, 625658400
- tz.transition 1990, 4, :o8, 638967600
- tz.transition 1990, 10, :o7, 657108000
- tz.transition 1991, 4, :o8, 671022000
- tz.transition 1991, 10, :o7, 688557600
- tz.transition 1992, 4, :o8, 702471600
- tz.transition 1992, 10, :o7, 720007200
- tz.transition 1993, 4, :o8, 733921200
- tz.transition 1993, 10, :o7, 752061600
- tz.transition 1994, 4, :o8, 765370800
- tz.transition 1994, 10, :o7, 783511200
- tz.transition 1995, 4, :o8, 796820400
- tz.transition 1995, 10, :o7, 814960800
- tz.transition 1996, 4, :o8, 828874800
- tz.transition 1996, 10, :o7, 846410400
- tz.transition 1997, 4, :o8, 860324400
- tz.transition 1997, 10, :o7, 877860000
- tz.transition 1998, 4, :o8, 891774000
- tz.transition 1998, 10, :o7, 909309600
- tz.transition 1999, 4, :o8, 923223600
- tz.transition 1999, 10, :o7, 941364000
- tz.transition 2000, 4, :o8, 954673200
- tz.transition 2000, 10, :o7, 972813600
- tz.transition 2001, 4, :o8, 986122800
- tz.transition 2001, 10, :o7, 1004263200
- tz.transition 2002, 4, :o8, 1018177200
- tz.transition 2002, 10, :o7, 1035712800
- tz.transition 2003, 4, :o8, 1049626800
- tz.transition 2003, 10, :o7, 1067162400
- tz.transition 2004, 4, :o8, 1081076400
- tz.transition 2004, 10, :o7, 1099216800
- tz.transition 2005, 4, :o8, 1112526000
- tz.transition 2005, 10, :o7, 1130666400
- tz.transition 2006, 4, :o8, 1143975600
- tz.transition 2006, 10, :o7, 1162116000
- tz.transition 2007, 3, :o8, 1173610800
- tz.transition 2007, 11, :o7, 1194170400
- tz.transition 2008, 3, :o8, 1205060400
- tz.transition 2008, 11, :o7, 1225620000
- tz.transition 2009, 3, :o8, 1236510000
- tz.transition 2009, 11, :o7, 1257069600
- tz.transition 2010, 3, :o8, 1268564400
- tz.transition 2010, 11, :o7, 1289124000
- tz.transition 2011, 3, :o8, 1300014000
- tz.transition 2011, 11, :o7, 1320573600
- tz.transition 2012, 3, :o8, 1331463600
- tz.transition 2012, 11, :o7, 1352023200
- tz.transition 2013, 3, :o8, 1362913200
- tz.transition 2013, 11, :o7, 1383472800
- tz.transition 2014, 3, :o8, 1394362800
- tz.transition 2014, 11, :o7, 1414922400
- tz.transition 2015, 3, :o8, 1425812400
- tz.transition 2015, 11, :o7, 1446372000
- tz.transition 2016, 3, :o8, 1457866800
- tz.transition 2016, 11, :o7, 1478426400
- tz.transition 2017, 3, :o8, 1489316400
- tz.transition 2017, 11, :o7, 1509876000
- tz.transition 2018, 3, :o8, 1520766000
- tz.transition 2018, 11, :o7, 1541325600
- tz.transition 2019, 3, :o8, 1552215600
- tz.transition 2019, 11, :o7, 1572775200
- tz.transition 2020, 3, :o8, 1583665200
- tz.transition 2020, 11, :o7, 1604224800
- tz.transition 2021, 3, :o8, 1615719600
- tz.transition 2021, 11, :o7, 1636279200
- tz.transition 2022, 3, :o8, 1647169200
- tz.transition 2022, 11, :o7, 1667728800
- tz.transition 2023, 3, :o8, 1678618800
- tz.transition 2023, 11, :o7, 1699178400
- tz.transition 2024, 3, :o8, 1710068400
- tz.transition 2024, 11, :o7, 1730628000
- tz.transition 2025, 3, :o8, 1741518000
- tz.transition 2025, 11, :o7, 1762077600
- tz.transition 2026, 3, :o8, 1772967600
- tz.transition 2026, 11, :o7, 1793527200
- tz.transition 2027, 3, :o8, 1805022000
- tz.transition 2027, 11, :o7, 1825581600
- tz.transition 2028, 3, :o8, 1836471600
- tz.transition 2028, 11, :o7, 1857031200
- tz.transition 2029, 3, :o8, 1867921200
- tz.transition 2029, 11, :o7, 1888480800
- tz.transition 2030, 3, :o8, 1899370800
- tz.transition 2030, 11, :o7, 1919930400
- tz.transition 2031, 3, :o8, 1930820400
- tz.transition 2031, 11, :o7, 1951380000
- tz.transition 2032, 3, :o8, 1962874800
- tz.transition 2032, 11, :o7, 1983434400
- tz.transition 2033, 3, :o8, 1994324400
- tz.transition 2033, 11, :o7, 2014884000
- tz.transition 2034, 3, :o8, 2025774000
- tz.transition 2034, 11, :o7, 2046333600
- tz.transition 2035, 3, :o8, 2057223600
- tz.transition 2035, 11, :o7, 2077783200
- tz.transition 2036, 3, :o8, 2088673200
- tz.transition 2036, 11, :o7, 2109232800
- tz.transition 2037, 3, :o8, 2120122800
- tz.transition 2037, 11, :o7, 2140682400
- tz.transition 2038, 3, :o8, 59171927, 24
- tz.transition 2038, 11, :o7, 29588819, 12
- tz.transition 2039, 3, :o8, 59180663, 24
- tz.transition 2039, 11, :o7, 29593187, 12
- tz.transition 2040, 3, :o8, 59189399, 24
- tz.transition 2040, 11, :o7, 29597555, 12
- tz.transition 2041, 3, :o8, 59198135, 24
- tz.transition 2041, 11, :o7, 29601923, 12
- tz.transition 2042, 3, :o8, 59206871, 24
- tz.transition 2042, 11, :o7, 29606291, 12
- tz.transition 2043, 3, :o8, 59215607, 24
- tz.transition 2043, 11, :o7, 29610659, 12
- tz.transition 2044, 3, :o8, 59224511, 24
- tz.transition 2044, 11, :o7, 29615111, 12
- tz.transition 2045, 3, :o8, 59233247, 24
- tz.transition 2045, 11, :o7, 29619479, 12
- tz.transition 2046, 3, :o8, 59241983, 24
- tz.transition 2046, 11, :o7, 29623847, 12
- tz.transition 2047, 3, :o8, 59250719, 24
- tz.transition 2047, 11, :o7, 29628215, 12
- tz.transition 2048, 3, :o8, 59259455, 24
- tz.transition 2048, 11, :o7, 29632583, 12
- tz.transition 2049, 3, :o8, 59268359, 24
- tz.transition 2049, 11, :o7, 29637035, 12
- tz.transition 2050, 3, :o8, 59277095, 24
- tz.transition 2050, 11, :o7, 29641403, 12
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/La_Paz.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/La_Paz.rb
deleted file mode 100644
index 45c907899f..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/La_Paz.rb
+++ /dev/null
@@ -1,22 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module La_Paz
- include TimezoneDefinition
-
- timezone 'America/La_Paz' do |tz|
- tz.offset :o0, -16356, 0, :LMT
- tz.offset :o1, -16356, 0, :CMT
- tz.offset :o2, -16356, 3600, :BOST
- tz.offset :o3, -14400, 0, :BOT
-
- tz.transition 1890, 1, :o1, 17361854563, 7200
- tz.transition 1931, 10, :o2, 17471733763, 7200
- tz.transition 1932, 3, :o3, 17472871063, 7200
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Lima.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Lima.rb
deleted file mode 100644
index af68ac29f7..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Lima.rb
+++ /dev/null
@@ -1,35 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module Lima
- include TimezoneDefinition
-
- timezone 'America/Lima' do |tz|
- tz.offset :o0, -18492, 0, :LMT
- tz.offset :o1, -18516, 0, :LMT
- tz.offset :o2, -18000, 0, :PET
- tz.offset :o3, -18000, 3600, :PEST
-
- tz.transition 1890, 1, :o1, 17361854741, 7200
- tz.transition 1908, 7, :o2, 17410685143, 7200
- tz.transition 1938, 1, :o3, 58293593, 24
- tz.transition 1938, 4, :o2, 7286969, 3
- tz.transition 1938, 9, :o3, 58300001, 24
- tz.transition 1939, 3, :o2, 7288046, 3
- tz.transition 1939, 9, :o3, 58308737, 24
- tz.transition 1940, 3, :o2, 7289138, 3
- tz.transition 1986, 1, :o3, 504939600
- tz.transition 1986, 4, :o2, 512712000
- tz.transition 1987, 1, :o3, 536475600
- tz.transition 1987, 4, :o2, 544248000
- tz.transition 1990, 1, :o3, 631170000
- tz.transition 1990, 4, :o2, 638942400
- tz.transition 1994, 1, :o3, 757400400
- tz.transition 1994, 4, :o2, 765172800
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Los_Angeles.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Los_Angeles.rb
deleted file mode 100644
index 16007fd675..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Los_Angeles.rb
+++ /dev/null
@@ -1,232 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module Los_Angeles
- include TimezoneDefinition
-
- timezone 'America/Los_Angeles' do |tz|
- tz.offset :o0, -28378, 0, :LMT
- tz.offset :o1, -28800, 0, :PST
- tz.offset :o2, -28800, 3600, :PDT
- tz.offset :o3, -28800, 3600, :PWT
- tz.offset :o4, -28800, 3600, :PPT
-
- tz.transition 1883, 11, :o1, 7227400, 3
- tz.transition 1918, 3, :o2, 29060207, 12
- tz.transition 1918, 10, :o1, 19375151, 8
- tz.transition 1919, 3, :o2, 29064575, 12
- tz.transition 1919, 10, :o1, 19378063, 8
- tz.transition 1942, 2, :o3, 29164799, 12
- tz.transition 1945, 8, :o4, 58360379, 24
- tz.transition 1945, 9, :o1, 19453831, 8
- tz.transition 1948, 3, :o2, 29191499, 12
- tz.transition 1949, 1, :o1, 19463343, 8
- tz.transition 1950, 4, :o2, 29200823, 12
- tz.transition 1950, 9, :o1, 19468391, 8
- tz.transition 1951, 4, :o2, 29205191, 12
- tz.transition 1951, 9, :o1, 19471359, 8
- tz.transition 1952, 4, :o2, 29209559, 12
- tz.transition 1952, 9, :o1, 19474271, 8
- tz.transition 1953, 4, :o2, 29213927, 12
- tz.transition 1953, 9, :o1, 19477183, 8
- tz.transition 1954, 4, :o2, 29218295, 12
- tz.transition 1954, 9, :o1, 19480095, 8
- tz.transition 1955, 4, :o2, 29222663, 12
- tz.transition 1955, 9, :o1, 19483007, 8
- tz.transition 1956, 4, :o2, 29227115, 12
- tz.transition 1956, 9, :o1, 19485975, 8
- tz.transition 1957, 4, :o2, 29231483, 12
- tz.transition 1957, 9, :o1, 19488887, 8
- tz.transition 1958, 4, :o2, 29235851, 12
- tz.transition 1958, 9, :o1, 19491799, 8
- tz.transition 1959, 4, :o2, 29240219, 12
- tz.transition 1959, 9, :o1, 19494711, 8
- tz.transition 1960, 4, :o2, 29244587, 12
- tz.transition 1960, 9, :o1, 19497623, 8
- tz.transition 1961, 4, :o2, 29249039, 12
- tz.transition 1961, 9, :o1, 19500535, 8
- tz.transition 1962, 4, :o2, 29253407, 12
- tz.transition 1962, 10, :o1, 19503727, 8
- tz.transition 1963, 4, :o2, 29257775, 12
- tz.transition 1963, 10, :o1, 19506639, 8
- tz.transition 1964, 4, :o2, 29262143, 12
- tz.transition 1964, 10, :o1, 19509551, 8
- tz.transition 1965, 4, :o2, 29266511, 12
- tz.transition 1965, 10, :o1, 19512519, 8
- tz.transition 1966, 4, :o2, 29270879, 12
- tz.transition 1966, 10, :o1, 19515431, 8
- tz.transition 1967, 4, :o2, 29275331, 12
- tz.transition 1967, 10, :o1, 19518343, 8
- tz.transition 1968, 4, :o2, 29279699, 12
- tz.transition 1968, 10, :o1, 19521255, 8
- tz.transition 1969, 4, :o2, 29284067, 12
- tz.transition 1969, 10, :o1, 19524167, 8
- tz.transition 1970, 4, :o2, 9972000
- tz.transition 1970, 10, :o1, 25693200
- tz.transition 1971, 4, :o2, 41421600
- tz.transition 1971, 10, :o1, 57747600
- tz.transition 1972, 4, :o2, 73476000
- tz.transition 1972, 10, :o1, 89197200
- tz.transition 1973, 4, :o2, 104925600
- tz.transition 1973, 10, :o1, 120646800
- tz.transition 1974, 1, :o2, 126698400
- tz.transition 1974, 10, :o1, 152096400
- tz.transition 1975, 2, :o2, 162381600
- tz.transition 1975, 10, :o1, 183546000
- tz.transition 1976, 4, :o2, 199274400
- tz.transition 1976, 10, :o1, 215600400
- tz.transition 1977, 4, :o2, 230724000
- tz.transition 1977, 10, :o1, 247050000
- tz.transition 1978, 4, :o2, 262778400
- tz.transition 1978, 10, :o1, 278499600
- tz.transition 1979, 4, :o2, 294228000
- tz.transition 1979, 10, :o1, 309949200
- tz.transition 1980, 4, :o2, 325677600
- tz.transition 1980, 10, :o1, 341398800
- tz.transition 1981, 4, :o2, 357127200
- tz.transition 1981, 10, :o1, 372848400
- tz.transition 1982, 4, :o2, 388576800
- tz.transition 1982, 10, :o1, 404902800
- tz.transition 1983, 4, :o2, 420026400
- tz.transition 1983, 10, :o1, 436352400
- tz.transition 1984, 4, :o2, 452080800
- tz.transition 1984, 10, :o1, 467802000
- tz.transition 1985, 4, :o2, 483530400
- tz.transition 1985, 10, :o1, 499251600
- tz.transition 1986, 4, :o2, 514980000
- tz.transition 1986, 10, :o1, 530701200
- tz.transition 1987, 4, :o2, 544615200
- tz.transition 1987, 10, :o1, 562150800
- tz.transition 1988, 4, :o2, 576064800
- tz.transition 1988, 10, :o1, 594205200
- tz.transition 1989, 4, :o2, 607514400
- tz.transition 1989, 10, :o1, 625654800
- tz.transition 1990, 4, :o2, 638964000
- tz.transition 1990, 10, :o1, 657104400
- tz.transition 1991, 4, :o2, 671018400
- tz.transition 1991, 10, :o1, 688554000
- tz.transition 1992, 4, :o2, 702468000
- tz.transition 1992, 10, :o1, 720003600
- tz.transition 1993, 4, :o2, 733917600
- tz.transition 1993, 10, :o1, 752058000
- tz.transition 1994, 4, :o2, 765367200
- tz.transition 1994, 10, :o1, 783507600
- tz.transition 1995, 4, :o2, 796816800
- tz.transition 1995, 10, :o1, 814957200
- tz.transition 1996, 4, :o2, 828871200
- tz.transition 1996, 10, :o1, 846406800
- tz.transition 1997, 4, :o2, 860320800
- tz.transition 1997, 10, :o1, 877856400
- tz.transition 1998, 4, :o2, 891770400
- tz.transition 1998, 10, :o1, 909306000
- tz.transition 1999, 4, :o2, 923220000
- tz.transition 1999, 10, :o1, 941360400
- tz.transition 2000, 4, :o2, 954669600
- tz.transition 2000, 10, :o1, 972810000
- tz.transition 2001, 4, :o2, 986119200
- tz.transition 2001, 10, :o1, 1004259600
- tz.transition 2002, 4, :o2, 1018173600
- tz.transition 2002, 10, :o1, 1035709200
- tz.transition 2003, 4, :o2, 1049623200
- tz.transition 2003, 10, :o1, 1067158800
- tz.transition 2004, 4, :o2, 1081072800
- tz.transition 2004, 10, :o1, 1099213200
- tz.transition 2005, 4, :o2, 1112522400
- tz.transition 2005, 10, :o1, 1130662800
- tz.transition 2006, 4, :o2, 1143972000
- tz.transition 2006, 10, :o1, 1162112400
- tz.transition 2007, 3, :o2, 1173607200
- tz.transition 2007, 11, :o1, 1194166800
- tz.transition 2008, 3, :o2, 1205056800
- tz.transition 2008, 11, :o1, 1225616400
- tz.transition 2009, 3, :o2, 1236506400
- tz.transition 2009, 11, :o1, 1257066000
- tz.transition 2010, 3, :o2, 1268560800
- tz.transition 2010, 11, :o1, 1289120400
- tz.transition 2011, 3, :o2, 1300010400
- tz.transition 2011, 11, :o1, 1320570000
- tz.transition 2012, 3, :o2, 1331460000
- tz.transition 2012, 11, :o1, 1352019600
- tz.transition 2013, 3, :o2, 1362909600
- tz.transition 2013, 11, :o1, 1383469200
- tz.transition 2014, 3, :o2, 1394359200
- tz.transition 2014, 11, :o1, 1414918800
- tz.transition 2015, 3, :o2, 1425808800
- tz.transition 2015, 11, :o1, 1446368400
- tz.transition 2016, 3, :o2, 1457863200
- tz.transition 2016, 11, :o1, 1478422800
- tz.transition 2017, 3, :o2, 1489312800
- tz.transition 2017, 11, :o1, 1509872400
- tz.transition 2018, 3, :o2, 1520762400
- tz.transition 2018, 11, :o1, 1541322000
- tz.transition 2019, 3, :o2, 1552212000
- tz.transition 2019, 11, :o1, 1572771600
- tz.transition 2020, 3, :o2, 1583661600
- tz.transition 2020, 11, :o1, 1604221200
- tz.transition 2021, 3, :o2, 1615716000
- tz.transition 2021, 11, :o1, 1636275600
- tz.transition 2022, 3, :o2, 1647165600
- tz.transition 2022, 11, :o1, 1667725200
- tz.transition 2023, 3, :o2, 1678615200
- tz.transition 2023, 11, :o1, 1699174800
- tz.transition 2024, 3, :o2, 1710064800
- tz.transition 2024, 11, :o1, 1730624400
- tz.transition 2025, 3, :o2, 1741514400
- tz.transition 2025, 11, :o1, 1762074000
- tz.transition 2026, 3, :o2, 1772964000
- tz.transition 2026, 11, :o1, 1793523600
- tz.transition 2027, 3, :o2, 1805018400
- tz.transition 2027, 11, :o1, 1825578000
- tz.transition 2028, 3, :o2, 1836468000
- tz.transition 2028, 11, :o1, 1857027600
- tz.transition 2029, 3, :o2, 1867917600
- tz.transition 2029, 11, :o1, 1888477200
- tz.transition 2030, 3, :o2, 1899367200
- tz.transition 2030, 11, :o1, 1919926800
- tz.transition 2031, 3, :o2, 1930816800
- tz.transition 2031, 11, :o1, 1951376400
- tz.transition 2032, 3, :o2, 1962871200
- tz.transition 2032, 11, :o1, 1983430800
- tz.transition 2033, 3, :o2, 1994320800
- tz.transition 2033, 11, :o1, 2014880400
- tz.transition 2034, 3, :o2, 2025770400
- tz.transition 2034, 11, :o1, 2046330000
- tz.transition 2035, 3, :o2, 2057220000
- tz.transition 2035, 11, :o1, 2077779600
- tz.transition 2036, 3, :o2, 2088669600
- tz.transition 2036, 11, :o1, 2109229200
- tz.transition 2037, 3, :o2, 2120119200
- tz.transition 2037, 11, :o1, 2140678800
- tz.transition 2038, 3, :o2, 29585963, 12
- tz.transition 2038, 11, :o1, 19725879, 8
- tz.transition 2039, 3, :o2, 29590331, 12
- tz.transition 2039, 11, :o1, 19728791, 8
- tz.transition 2040, 3, :o2, 29594699, 12
- tz.transition 2040, 11, :o1, 19731703, 8
- tz.transition 2041, 3, :o2, 29599067, 12
- tz.transition 2041, 11, :o1, 19734615, 8
- tz.transition 2042, 3, :o2, 29603435, 12
- tz.transition 2042, 11, :o1, 19737527, 8
- tz.transition 2043, 3, :o2, 29607803, 12
- tz.transition 2043, 11, :o1, 19740439, 8
- tz.transition 2044, 3, :o2, 29612255, 12
- tz.transition 2044, 11, :o1, 19743407, 8
- tz.transition 2045, 3, :o2, 29616623, 12
- tz.transition 2045, 11, :o1, 19746319, 8
- tz.transition 2046, 3, :o2, 29620991, 12
- tz.transition 2046, 11, :o1, 19749231, 8
- tz.transition 2047, 3, :o2, 29625359, 12
- tz.transition 2047, 11, :o1, 19752143, 8
- tz.transition 2048, 3, :o2, 29629727, 12
- tz.transition 2048, 11, :o1, 19755055, 8
- tz.transition 2049, 3, :o2, 29634179, 12
- tz.transition 2049, 11, :o1, 19758023, 8
- tz.transition 2050, 3, :o2, 29638547, 12
- tz.transition 2050, 11, :o1, 19760935, 8
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Mazatlan.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Mazatlan.rb
deleted file mode 100644
index ba9e6efcf1..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Mazatlan.rb
+++ /dev/null
@@ -1,139 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module Mazatlan
- include TimezoneDefinition
-
- timezone 'America/Mazatlan' do |tz|
- tz.offset :o0, -25540, 0, :LMT
- tz.offset :o1, -25200, 0, :MST
- tz.offset :o2, -21600, 0, :CST
- tz.offset :o3, -28800, 0, :PST
- tz.offset :o4, -25200, 3600, :MDT
-
- tz.transition 1922, 1, :o1, 58153339, 24
- tz.transition 1927, 6, :o2, 9700171, 4
- tz.transition 1930, 11, :o1, 9705183, 4
- tz.transition 1931, 5, :o2, 9705855, 4
- tz.transition 1931, 10, :o1, 9706463, 4
- tz.transition 1932, 4, :o2, 58243171, 24
- tz.transition 1942, 4, :o1, 9721895, 4
- tz.transition 1949, 1, :o3, 58390339, 24
- tz.transition 1970, 1, :o1, 28800
- tz.transition 1996, 4, :o4, 828867600
- tz.transition 1996, 10, :o1, 846403200
- tz.transition 1997, 4, :o4, 860317200
- tz.transition 1997, 10, :o1, 877852800
- tz.transition 1998, 4, :o4, 891766800
- tz.transition 1998, 10, :o1, 909302400
- tz.transition 1999, 4, :o4, 923216400
- tz.transition 1999, 10, :o1, 941356800
- tz.transition 2000, 4, :o4, 954666000
- tz.transition 2000, 10, :o1, 972806400
- tz.transition 2001, 5, :o4, 989139600
- tz.transition 2001, 9, :o1, 1001836800
- tz.transition 2002, 4, :o4, 1018170000
- tz.transition 2002, 10, :o1, 1035705600
- tz.transition 2003, 4, :o4, 1049619600
- tz.transition 2003, 10, :o1, 1067155200
- tz.transition 2004, 4, :o4, 1081069200
- tz.transition 2004, 10, :o1, 1099209600
- tz.transition 2005, 4, :o4, 1112518800
- tz.transition 2005, 10, :o1, 1130659200
- tz.transition 2006, 4, :o4, 1143968400
- tz.transition 2006, 10, :o1, 1162108800
- tz.transition 2007, 4, :o4, 1175418000
- tz.transition 2007, 10, :o1, 1193558400
- tz.transition 2008, 4, :o4, 1207472400
- tz.transition 2008, 10, :o1, 1225008000
- tz.transition 2009, 4, :o4, 1238922000
- tz.transition 2009, 10, :o1, 1256457600
- tz.transition 2010, 4, :o4, 1270371600
- tz.transition 2010, 10, :o1, 1288512000
- tz.transition 2011, 4, :o4, 1301821200
- tz.transition 2011, 10, :o1, 1319961600
- tz.transition 2012, 4, :o4, 1333270800
- tz.transition 2012, 10, :o1, 1351411200
- tz.transition 2013, 4, :o4, 1365325200
- tz.transition 2013, 10, :o1, 1382860800
- tz.transition 2014, 4, :o4, 1396774800
- tz.transition 2014, 10, :o1, 1414310400
- tz.transition 2015, 4, :o4, 1428224400
- tz.transition 2015, 10, :o1, 1445760000
- tz.transition 2016, 4, :o4, 1459674000
- tz.transition 2016, 10, :o1, 1477814400
- tz.transition 2017, 4, :o4, 1491123600
- tz.transition 2017, 10, :o1, 1509264000
- tz.transition 2018, 4, :o4, 1522573200
- tz.transition 2018, 10, :o1, 1540713600
- tz.transition 2019, 4, :o4, 1554627600
- tz.transition 2019, 10, :o1, 1572163200
- tz.transition 2020, 4, :o4, 1586077200
- tz.transition 2020, 10, :o1, 1603612800
- tz.transition 2021, 4, :o4, 1617526800
- tz.transition 2021, 10, :o1, 1635667200
- tz.transition 2022, 4, :o4, 1648976400
- tz.transition 2022, 10, :o1, 1667116800
- tz.transition 2023, 4, :o4, 1680426000
- tz.transition 2023, 10, :o1, 1698566400
- tz.transition 2024, 4, :o4, 1712480400
- tz.transition 2024, 10, :o1, 1730016000
- tz.transition 2025, 4, :o4, 1743930000
- tz.transition 2025, 10, :o1, 1761465600
- tz.transition 2026, 4, :o4, 1775379600
- tz.transition 2026, 10, :o1, 1792915200
- tz.transition 2027, 4, :o4, 1806829200
- tz.transition 2027, 10, :o1, 1824969600
- tz.transition 2028, 4, :o4, 1838278800
- tz.transition 2028, 10, :o1, 1856419200
- tz.transition 2029, 4, :o4, 1869728400
- tz.transition 2029, 10, :o1, 1887868800
- tz.transition 2030, 4, :o4, 1901782800
- tz.transition 2030, 10, :o1, 1919318400
- tz.transition 2031, 4, :o4, 1933232400
- tz.transition 2031, 10, :o1, 1950768000
- tz.transition 2032, 4, :o4, 1964682000
- tz.transition 2032, 10, :o1, 1982822400
- tz.transition 2033, 4, :o4, 1996131600
- tz.transition 2033, 10, :o1, 2014272000
- tz.transition 2034, 4, :o4, 2027581200
- tz.transition 2034, 10, :o1, 2045721600
- tz.transition 2035, 4, :o4, 2059030800
- tz.transition 2035, 10, :o1, 2077171200
- tz.transition 2036, 4, :o4, 2091085200
- tz.transition 2036, 10, :o1, 2108620800
- tz.transition 2037, 4, :o4, 2122534800
- tz.transition 2037, 10, :o1, 2140070400
- tz.transition 2038, 4, :o4, 19724143, 8
- tz.transition 2038, 10, :o1, 14794367, 6
- tz.transition 2039, 4, :o4, 19727055, 8
- tz.transition 2039, 10, :o1, 14796551, 6
- tz.transition 2040, 4, :o4, 19729967, 8
- tz.transition 2040, 10, :o1, 14798735, 6
- tz.transition 2041, 4, :o4, 19732935, 8
- tz.transition 2041, 10, :o1, 14800919, 6
- tz.transition 2042, 4, :o4, 19735847, 8
- tz.transition 2042, 10, :o1, 14803103, 6
- tz.transition 2043, 4, :o4, 19738759, 8
- tz.transition 2043, 10, :o1, 14805287, 6
- tz.transition 2044, 4, :o4, 19741671, 8
- tz.transition 2044, 10, :o1, 14807513, 6
- tz.transition 2045, 4, :o4, 19744583, 8
- tz.transition 2045, 10, :o1, 14809697, 6
- tz.transition 2046, 4, :o4, 19747495, 8
- tz.transition 2046, 10, :o1, 14811881, 6
- tz.transition 2047, 4, :o4, 19750463, 8
- tz.transition 2047, 10, :o1, 14814065, 6
- tz.transition 2048, 4, :o4, 19753375, 8
- tz.transition 2048, 10, :o1, 14816249, 6
- tz.transition 2049, 4, :o4, 19756287, 8
- tz.transition 2049, 10, :o1, 14818475, 6
- tz.transition 2050, 4, :o4, 19759199, 8
- tz.transition 2050, 10, :o1, 14820659, 6
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Mexico_City.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Mexico_City.rb
deleted file mode 100644
index 2347fce647..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Mexico_City.rb
+++ /dev/null
@@ -1,144 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module Mexico_City
- include TimezoneDefinition
-
- timezone 'America/Mexico_City' do |tz|
- tz.offset :o0, -23796, 0, :LMT
- tz.offset :o1, -25200, 0, :MST
- tz.offset :o2, -21600, 0, :CST
- tz.offset :o3, -21600, 3600, :CDT
- tz.offset :o4, -21600, 3600, :CWT
-
- tz.transition 1922, 1, :o1, 58153339, 24
- tz.transition 1927, 6, :o2, 9700171, 4
- tz.transition 1930, 11, :o1, 9705183, 4
- tz.transition 1931, 5, :o2, 9705855, 4
- tz.transition 1931, 10, :o1, 9706463, 4
- tz.transition 1932, 4, :o2, 58243171, 24
- tz.transition 1939, 2, :o3, 9717199, 4
- tz.transition 1939, 6, :o2, 58306553, 24
- tz.transition 1940, 12, :o3, 9719891, 4
- tz.transition 1941, 4, :o2, 58322057, 24
- tz.transition 1943, 12, :o4, 9724299, 4
- tz.transition 1944, 5, :o2, 58349081, 24
- tz.transition 1950, 2, :o3, 9733299, 4
- tz.transition 1950, 7, :o2, 58403825, 24
- tz.transition 1996, 4, :o3, 828864000
- tz.transition 1996, 10, :o2, 846399600
- tz.transition 1997, 4, :o3, 860313600
- tz.transition 1997, 10, :o2, 877849200
- tz.transition 1998, 4, :o3, 891763200
- tz.transition 1998, 10, :o2, 909298800
- tz.transition 1999, 4, :o3, 923212800
- tz.transition 1999, 10, :o2, 941353200
- tz.transition 2000, 4, :o3, 954662400
- tz.transition 2000, 10, :o2, 972802800
- tz.transition 2001, 5, :o3, 989136000
- tz.transition 2001, 9, :o2, 1001833200
- tz.transition 2002, 4, :o3, 1018166400
- tz.transition 2002, 10, :o2, 1035702000
- tz.transition 2003, 4, :o3, 1049616000
- tz.transition 2003, 10, :o2, 1067151600
- tz.transition 2004, 4, :o3, 1081065600
- tz.transition 2004, 10, :o2, 1099206000
- tz.transition 2005, 4, :o3, 1112515200
- tz.transition 2005, 10, :o2, 1130655600
- tz.transition 2006, 4, :o3, 1143964800
- tz.transition 2006, 10, :o2, 1162105200
- tz.transition 2007, 4, :o3, 1175414400
- tz.transition 2007, 10, :o2, 1193554800
- tz.transition 2008, 4, :o3, 1207468800
- tz.transition 2008, 10, :o2, 1225004400
- tz.transition 2009, 4, :o3, 1238918400
- tz.transition 2009, 10, :o2, 1256454000
- tz.transition 2010, 4, :o3, 1270368000
- tz.transition 2010, 10, :o2, 1288508400
- tz.transition 2011, 4, :o3, 1301817600
- tz.transition 2011, 10, :o2, 1319958000
- tz.transition 2012, 4, :o3, 1333267200
- tz.transition 2012, 10, :o2, 1351407600
- tz.transition 2013, 4, :o3, 1365321600
- tz.transition 2013, 10, :o2, 1382857200
- tz.transition 2014, 4, :o3, 1396771200
- tz.transition 2014, 10, :o2, 1414306800
- tz.transition 2015, 4, :o3, 1428220800
- tz.transition 2015, 10, :o2, 1445756400
- tz.transition 2016, 4, :o3, 1459670400
- tz.transition 2016, 10, :o2, 1477810800
- tz.transition 2017, 4, :o3, 1491120000
- tz.transition 2017, 10, :o2, 1509260400
- tz.transition 2018, 4, :o3, 1522569600
- tz.transition 2018, 10, :o2, 1540710000
- tz.transition 2019, 4, :o3, 1554624000
- tz.transition 2019, 10, :o2, 1572159600
- tz.transition 2020, 4, :o3, 1586073600
- tz.transition 2020, 10, :o2, 1603609200
- tz.transition 2021, 4, :o3, 1617523200
- tz.transition 2021, 10, :o2, 1635663600
- tz.transition 2022, 4, :o3, 1648972800
- tz.transition 2022, 10, :o2, 1667113200
- tz.transition 2023, 4, :o3, 1680422400
- tz.transition 2023, 10, :o2, 1698562800
- tz.transition 2024, 4, :o3, 1712476800
- tz.transition 2024, 10, :o2, 1730012400
- tz.transition 2025, 4, :o3, 1743926400
- tz.transition 2025, 10, :o2, 1761462000
- tz.transition 2026, 4, :o3, 1775376000
- tz.transition 2026, 10, :o2, 1792911600
- tz.transition 2027, 4, :o3, 1806825600
- tz.transition 2027, 10, :o2, 1824966000
- tz.transition 2028, 4, :o3, 1838275200
- tz.transition 2028, 10, :o2, 1856415600
- tz.transition 2029, 4, :o3, 1869724800
- tz.transition 2029, 10, :o2, 1887865200
- tz.transition 2030, 4, :o3, 1901779200
- tz.transition 2030, 10, :o2, 1919314800
- tz.transition 2031, 4, :o3, 1933228800
- tz.transition 2031, 10, :o2, 1950764400
- tz.transition 2032, 4, :o3, 1964678400
- tz.transition 2032, 10, :o2, 1982818800
- tz.transition 2033, 4, :o3, 1996128000
- tz.transition 2033, 10, :o2, 2014268400
- tz.transition 2034, 4, :o3, 2027577600
- tz.transition 2034, 10, :o2, 2045718000
- tz.transition 2035, 4, :o3, 2059027200
- tz.transition 2035, 10, :o2, 2077167600
- tz.transition 2036, 4, :o3, 2091081600
- tz.transition 2036, 10, :o2, 2108617200
- tz.transition 2037, 4, :o3, 2122531200
- tz.transition 2037, 10, :o2, 2140066800
- tz.transition 2038, 4, :o3, 14793107, 6
- tz.transition 2038, 10, :o2, 59177467, 24
- tz.transition 2039, 4, :o3, 14795291, 6
- tz.transition 2039, 10, :o2, 59186203, 24
- tz.transition 2040, 4, :o3, 14797475, 6
- tz.transition 2040, 10, :o2, 59194939, 24
- tz.transition 2041, 4, :o3, 14799701, 6
- tz.transition 2041, 10, :o2, 59203675, 24
- tz.transition 2042, 4, :o3, 14801885, 6
- tz.transition 2042, 10, :o2, 59212411, 24
- tz.transition 2043, 4, :o3, 14804069, 6
- tz.transition 2043, 10, :o2, 59221147, 24
- tz.transition 2044, 4, :o3, 14806253, 6
- tz.transition 2044, 10, :o2, 59230051, 24
- tz.transition 2045, 4, :o3, 14808437, 6
- tz.transition 2045, 10, :o2, 59238787, 24
- tz.transition 2046, 4, :o3, 14810621, 6
- tz.transition 2046, 10, :o2, 59247523, 24
- tz.transition 2047, 4, :o3, 14812847, 6
- tz.transition 2047, 10, :o2, 59256259, 24
- tz.transition 2048, 4, :o3, 14815031, 6
- tz.transition 2048, 10, :o2, 59264995, 24
- tz.transition 2049, 4, :o3, 14817215, 6
- tz.transition 2049, 10, :o2, 59273899, 24
- tz.transition 2050, 4, :o3, 14819399, 6
- tz.transition 2050, 10, :o2, 59282635, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Monterrey.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Monterrey.rb
deleted file mode 100644
index 5816a9eab1..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Monterrey.rb
+++ /dev/null
@@ -1,131 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module Monterrey
- include TimezoneDefinition
-
- timezone 'America/Monterrey' do |tz|
- tz.offset :o0, -24076, 0, :LMT
- tz.offset :o1, -21600, 0, :CST
- tz.offset :o2, -21600, 3600, :CDT
-
- tz.transition 1922, 1, :o1, 9692223, 4
- tz.transition 1988, 4, :o2, 576057600
- tz.transition 1988, 10, :o1, 594198000
- tz.transition 1996, 4, :o2, 828864000
- tz.transition 1996, 10, :o1, 846399600
- tz.transition 1997, 4, :o2, 860313600
- tz.transition 1997, 10, :o1, 877849200
- tz.transition 1998, 4, :o2, 891763200
- tz.transition 1998, 10, :o1, 909298800
- tz.transition 1999, 4, :o2, 923212800
- tz.transition 1999, 10, :o1, 941353200
- tz.transition 2000, 4, :o2, 954662400
- tz.transition 2000, 10, :o1, 972802800
- tz.transition 2001, 5, :o2, 989136000
- tz.transition 2001, 9, :o1, 1001833200
- tz.transition 2002, 4, :o2, 1018166400
- tz.transition 2002, 10, :o1, 1035702000
- tz.transition 2003, 4, :o2, 1049616000
- tz.transition 2003, 10, :o1, 1067151600
- tz.transition 2004, 4, :o2, 1081065600
- tz.transition 2004, 10, :o1, 1099206000
- tz.transition 2005, 4, :o2, 1112515200
- tz.transition 2005, 10, :o1, 1130655600
- tz.transition 2006, 4, :o2, 1143964800
- tz.transition 2006, 10, :o1, 1162105200
- tz.transition 2007, 4, :o2, 1175414400
- tz.transition 2007, 10, :o1, 1193554800
- tz.transition 2008, 4, :o2, 1207468800
- tz.transition 2008, 10, :o1, 1225004400
- tz.transition 2009, 4, :o2, 1238918400
- tz.transition 2009, 10, :o1, 1256454000
- tz.transition 2010, 4, :o2, 1270368000
- tz.transition 2010, 10, :o1, 1288508400
- tz.transition 2011, 4, :o2, 1301817600
- tz.transition 2011, 10, :o1, 1319958000
- tz.transition 2012, 4, :o2, 1333267200
- tz.transition 2012, 10, :o1, 1351407600
- tz.transition 2013, 4, :o2, 1365321600
- tz.transition 2013, 10, :o1, 1382857200
- tz.transition 2014, 4, :o2, 1396771200
- tz.transition 2014, 10, :o1, 1414306800
- tz.transition 2015, 4, :o2, 1428220800
- tz.transition 2015, 10, :o1, 1445756400
- tz.transition 2016, 4, :o2, 1459670400
- tz.transition 2016, 10, :o1, 1477810800
- tz.transition 2017, 4, :o2, 1491120000
- tz.transition 2017, 10, :o1, 1509260400
- tz.transition 2018, 4, :o2, 1522569600
- tz.transition 2018, 10, :o1, 1540710000
- tz.transition 2019, 4, :o2, 1554624000
- tz.transition 2019, 10, :o1, 1572159600
- tz.transition 2020, 4, :o2, 1586073600
- tz.transition 2020, 10, :o1, 1603609200
- tz.transition 2021, 4, :o2, 1617523200
- tz.transition 2021, 10, :o1, 1635663600
- tz.transition 2022, 4, :o2, 1648972800
- tz.transition 2022, 10, :o1, 1667113200
- tz.transition 2023, 4, :o2, 1680422400
- tz.transition 2023, 10, :o1, 1698562800
- tz.transition 2024, 4, :o2, 1712476800
- tz.transition 2024, 10, :o1, 1730012400
- tz.transition 2025, 4, :o2, 1743926400
- tz.transition 2025, 10, :o1, 1761462000
- tz.transition 2026, 4, :o2, 1775376000
- tz.transition 2026, 10, :o1, 1792911600
- tz.transition 2027, 4, :o2, 1806825600
- tz.transition 2027, 10, :o1, 1824966000
- tz.transition 2028, 4, :o2, 1838275200
- tz.transition 2028, 10, :o1, 1856415600
- tz.transition 2029, 4, :o2, 1869724800
- tz.transition 2029, 10, :o1, 1887865200
- tz.transition 2030, 4, :o2, 1901779200
- tz.transition 2030, 10, :o1, 1919314800
- tz.transition 2031, 4, :o2, 1933228800
- tz.transition 2031, 10, :o1, 1950764400
- tz.transition 2032, 4, :o2, 1964678400
- tz.transition 2032, 10, :o1, 1982818800
- tz.transition 2033, 4, :o2, 1996128000
- tz.transition 2033, 10, :o1, 2014268400
- tz.transition 2034, 4, :o2, 2027577600
- tz.transition 2034, 10, :o1, 2045718000
- tz.transition 2035, 4, :o2, 2059027200
- tz.transition 2035, 10, :o1, 2077167600
- tz.transition 2036, 4, :o2, 2091081600
- tz.transition 2036, 10, :o1, 2108617200
- tz.transition 2037, 4, :o2, 2122531200
- tz.transition 2037, 10, :o1, 2140066800
- tz.transition 2038, 4, :o2, 14793107, 6
- tz.transition 2038, 10, :o1, 59177467, 24
- tz.transition 2039, 4, :o2, 14795291, 6
- tz.transition 2039, 10, :o1, 59186203, 24
- tz.transition 2040, 4, :o2, 14797475, 6
- tz.transition 2040, 10, :o1, 59194939, 24
- tz.transition 2041, 4, :o2, 14799701, 6
- tz.transition 2041, 10, :o1, 59203675, 24
- tz.transition 2042, 4, :o2, 14801885, 6
- tz.transition 2042, 10, :o1, 59212411, 24
- tz.transition 2043, 4, :o2, 14804069, 6
- tz.transition 2043, 10, :o1, 59221147, 24
- tz.transition 2044, 4, :o2, 14806253, 6
- tz.transition 2044, 10, :o1, 59230051, 24
- tz.transition 2045, 4, :o2, 14808437, 6
- tz.transition 2045, 10, :o1, 59238787, 24
- tz.transition 2046, 4, :o2, 14810621, 6
- tz.transition 2046, 10, :o1, 59247523, 24
- tz.transition 2047, 4, :o2, 14812847, 6
- tz.transition 2047, 10, :o1, 59256259, 24
- tz.transition 2048, 4, :o2, 14815031, 6
- tz.transition 2048, 10, :o1, 59264995, 24
- tz.transition 2049, 4, :o2, 14817215, 6
- tz.transition 2049, 10, :o1, 59273899, 24
- tz.transition 2050, 4, :o2, 14819399, 6
- tz.transition 2050, 10, :o1, 59282635, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/New_York.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/New_York.rb
deleted file mode 100644
index 7d802bd2de..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/New_York.rb
+++ /dev/null
@@ -1,282 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module New_York
- include TimezoneDefinition
-
- timezone 'America/New_York' do |tz|
- tz.offset :o0, -17762, 0, :LMT
- tz.offset :o1, -18000, 0, :EST
- tz.offset :o2, -18000, 3600, :EDT
- tz.offset :o3, -18000, 3600, :EWT
- tz.offset :o4, -18000, 3600, :EPT
-
- tz.transition 1883, 11, :o1, 57819197, 24
- tz.transition 1918, 3, :o2, 58120411, 24
- tz.transition 1918, 10, :o1, 9687575, 4
- tz.transition 1919, 3, :o2, 58129147, 24
- tz.transition 1919, 10, :o1, 9689031, 4
- tz.transition 1920, 3, :o2, 58137883, 24
- tz.transition 1920, 10, :o1, 9690515, 4
- tz.transition 1921, 4, :o2, 58147291, 24
- tz.transition 1921, 9, :o1, 9691831, 4
- tz.transition 1922, 4, :o2, 58156195, 24
- tz.transition 1922, 9, :o1, 9693287, 4
- tz.transition 1923, 4, :o2, 58164931, 24
- tz.transition 1923, 9, :o1, 9694771, 4
- tz.transition 1924, 4, :o2, 58173667, 24
- tz.transition 1924, 9, :o1, 9696227, 4
- tz.transition 1925, 4, :o2, 58182403, 24
- tz.transition 1925, 9, :o1, 9697683, 4
- tz.transition 1926, 4, :o2, 58191139, 24
- tz.transition 1926, 9, :o1, 9699139, 4
- tz.transition 1927, 4, :o2, 58199875, 24
- tz.transition 1927, 9, :o1, 9700595, 4
- tz.transition 1928, 4, :o2, 58208779, 24
- tz.transition 1928, 9, :o1, 9702079, 4
- tz.transition 1929, 4, :o2, 58217515, 24
- tz.transition 1929, 9, :o1, 9703535, 4
- tz.transition 1930, 4, :o2, 58226251, 24
- tz.transition 1930, 9, :o1, 9704991, 4
- tz.transition 1931, 4, :o2, 58234987, 24
- tz.transition 1931, 9, :o1, 9706447, 4
- tz.transition 1932, 4, :o2, 58243723, 24
- tz.transition 1932, 9, :o1, 9707903, 4
- tz.transition 1933, 4, :o2, 58252627, 24
- tz.transition 1933, 9, :o1, 9709359, 4
- tz.transition 1934, 4, :o2, 58261363, 24
- tz.transition 1934, 9, :o1, 9710843, 4
- tz.transition 1935, 4, :o2, 58270099, 24
- tz.transition 1935, 9, :o1, 9712299, 4
- tz.transition 1936, 4, :o2, 58278835, 24
- tz.transition 1936, 9, :o1, 9713755, 4
- tz.transition 1937, 4, :o2, 58287571, 24
- tz.transition 1937, 9, :o1, 9715211, 4
- tz.transition 1938, 4, :o2, 58296307, 24
- tz.transition 1938, 9, :o1, 9716667, 4
- tz.transition 1939, 4, :o2, 58305211, 24
- tz.transition 1939, 9, :o1, 9718123, 4
- tz.transition 1940, 4, :o2, 58313947, 24
- tz.transition 1940, 9, :o1, 9719607, 4
- tz.transition 1941, 4, :o2, 58322683, 24
- tz.transition 1941, 9, :o1, 9721063, 4
- tz.transition 1942, 2, :o3, 58329595, 24
- tz.transition 1945, 8, :o4, 58360379, 24
- tz.transition 1945, 9, :o1, 9726915, 4
- tz.transition 1946, 4, :o2, 58366531, 24
- tz.transition 1946, 9, :o1, 9728371, 4
- tz.transition 1947, 4, :o2, 58375267, 24
- tz.transition 1947, 9, :o1, 9729827, 4
- tz.transition 1948, 4, :o2, 58384003, 24
- tz.transition 1948, 9, :o1, 9731283, 4
- tz.transition 1949, 4, :o2, 58392739, 24
- tz.transition 1949, 9, :o1, 9732739, 4
- tz.transition 1950, 4, :o2, 58401643, 24
- tz.transition 1950, 9, :o1, 9734195, 4
- tz.transition 1951, 4, :o2, 58410379, 24
- tz.transition 1951, 9, :o1, 9735679, 4
- tz.transition 1952, 4, :o2, 58419115, 24
- tz.transition 1952, 9, :o1, 9737135, 4
- tz.transition 1953, 4, :o2, 58427851, 24
- tz.transition 1953, 9, :o1, 9738591, 4
- tz.transition 1954, 4, :o2, 58436587, 24
- tz.transition 1954, 9, :o1, 9740047, 4
- tz.transition 1955, 4, :o2, 58445323, 24
- tz.transition 1955, 10, :o1, 9741643, 4
- tz.transition 1956, 4, :o2, 58454227, 24
- tz.transition 1956, 10, :o1, 9743099, 4
- tz.transition 1957, 4, :o2, 58462963, 24
- tz.transition 1957, 10, :o1, 9744555, 4
- tz.transition 1958, 4, :o2, 58471699, 24
- tz.transition 1958, 10, :o1, 9746011, 4
- tz.transition 1959, 4, :o2, 58480435, 24
- tz.transition 1959, 10, :o1, 9747467, 4
- tz.transition 1960, 4, :o2, 58489171, 24
- tz.transition 1960, 10, :o1, 9748951, 4
- tz.transition 1961, 4, :o2, 58498075, 24
- tz.transition 1961, 10, :o1, 9750407, 4
- tz.transition 1962, 4, :o2, 58506811, 24
- tz.transition 1962, 10, :o1, 9751863, 4
- tz.transition 1963, 4, :o2, 58515547, 24
- tz.transition 1963, 10, :o1, 9753319, 4
- tz.transition 1964, 4, :o2, 58524283, 24
- tz.transition 1964, 10, :o1, 9754775, 4
- tz.transition 1965, 4, :o2, 58533019, 24
- tz.transition 1965, 10, :o1, 9756259, 4
- tz.transition 1966, 4, :o2, 58541755, 24
- tz.transition 1966, 10, :o1, 9757715, 4
- tz.transition 1967, 4, :o2, 58550659, 24
- tz.transition 1967, 10, :o1, 9759171, 4
- tz.transition 1968, 4, :o2, 58559395, 24
- tz.transition 1968, 10, :o1, 9760627, 4
- tz.transition 1969, 4, :o2, 58568131, 24
- tz.transition 1969, 10, :o1, 9762083, 4
- tz.transition 1970, 4, :o2, 9961200
- tz.transition 1970, 10, :o1, 25682400
- tz.transition 1971, 4, :o2, 41410800
- tz.transition 1971, 10, :o1, 57736800
- tz.transition 1972, 4, :o2, 73465200
- tz.transition 1972, 10, :o1, 89186400
- tz.transition 1973, 4, :o2, 104914800
- tz.transition 1973, 10, :o1, 120636000
- tz.transition 1974, 1, :o2, 126687600
- tz.transition 1974, 10, :o1, 152085600
- tz.transition 1975, 2, :o2, 162370800
- tz.transition 1975, 10, :o1, 183535200
- tz.transition 1976, 4, :o2, 199263600
- tz.transition 1976, 10, :o1, 215589600
- tz.transition 1977, 4, :o2, 230713200
- tz.transition 1977, 10, :o1, 247039200
- tz.transition 1978, 4, :o2, 262767600
- tz.transition 1978, 10, :o1, 278488800
- tz.transition 1979, 4, :o2, 294217200
- tz.transition 1979, 10, :o1, 309938400
- tz.transition 1980, 4, :o2, 325666800
- tz.transition 1980, 10, :o1, 341388000
- tz.transition 1981, 4, :o2, 357116400
- tz.transition 1981, 10, :o1, 372837600
- tz.transition 1982, 4, :o2, 388566000
- tz.transition 1982, 10, :o1, 404892000
- tz.transition 1983, 4, :o2, 420015600
- tz.transition 1983, 10, :o1, 436341600
- tz.transition 1984, 4, :o2, 452070000
- tz.transition 1984, 10, :o1, 467791200
- tz.transition 1985, 4, :o2, 483519600
- tz.transition 1985, 10, :o1, 499240800
- tz.transition 1986, 4, :o2, 514969200
- tz.transition 1986, 10, :o1, 530690400
- tz.transition 1987, 4, :o2, 544604400
- tz.transition 1987, 10, :o1, 562140000
- tz.transition 1988, 4, :o2, 576054000
- tz.transition 1988, 10, :o1, 594194400
- tz.transition 1989, 4, :o2, 607503600
- tz.transition 1989, 10, :o1, 625644000
- tz.transition 1990, 4, :o2, 638953200
- tz.transition 1990, 10, :o1, 657093600
- tz.transition 1991, 4, :o2, 671007600
- tz.transition 1991, 10, :o1, 688543200
- tz.transition 1992, 4, :o2, 702457200
- tz.transition 1992, 10, :o1, 719992800
- tz.transition 1993, 4, :o2, 733906800
- tz.transition 1993, 10, :o1, 752047200
- tz.transition 1994, 4, :o2, 765356400
- tz.transition 1994, 10, :o1, 783496800
- tz.transition 1995, 4, :o2, 796806000
- tz.transition 1995, 10, :o1, 814946400
- tz.transition 1996, 4, :o2, 828860400
- tz.transition 1996, 10, :o1, 846396000
- tz.transition 1997, 4, :o2, 860310000
- tz.transition 1997, 10, :o1, 877845600
- tz.transition 1998, 4, :o2, 891759600
- tz.transition 1998, 10, :o1, 909295200
- tz.transition 1999, 4, :o2, 923209200
- tz.transition 1999, 10, :o1, 941349600
- tz.transition 2000, 4, :o2, 954658800
- tz.transition 2000, 10, :o1, 972799200
- tz.transition 2001, 4, :o2, 986108400
- tz.transition 2001, 10, :o1, 1004248800
- tz.transition 2002, 4, :o2, 1018162800
- tz.transition 2002, 10, :o1, 1035698400
- tz.transition 2003, 4, :o2, 1049612400
- tz.transition 2003, 10, :o1, 1067148000
- tz.transition 2004, 4, :o2, 1081062000
- tz.transition 2004, 10, :o1, 1099202400
- tz.transition 2005, 4, :o2, 1112511600
- tz.transition 2005, 10, :o1, 1130652000
- tz.transition 2006, 4, :o2, 1143961200
- tz.transition 2006, 10, :o1, 1162101600
- tz.transition 2007, 3, :o2, 1173596400
- tz.transition 2007, 11, :o1, 1194156000
- tz.transition 2008, 3, :o2, 1205046000
- tz.transition 2008, 11, :o1, 1225605600
- tz.transition 2009, 3, :o2, 1236495600
- tz.transition 2009, 11, :o1, 1257055200
- tz.transition 2010, 3, :o2, 1268550000
- tz.transition 2010, 11, :o1, 1289109600
- tz.transition 2011, 3, :o2, 1299999600
- tz.transition 2011, 11, :o1, 1320559200
- tz.transition 2012, 3, :o2, 1331449200
- tz.transition 2012, 11, :o1, 1352008800
- tz.transition 2013, 3, :o2, 1362898800
- tz.transition 2013, 11, :o1, 1383458400
- tz.transition 2014, 3, :o2, 1394348400
- tz.transition 2014, 11, :o1, 1414908000
- tz.transition 2015, 3, :o2, 1425798000
- tz.transition 2015, 11, :o1, 1446357600
- tz.transition 2016, 3, :o2, 1457852400
- tz.transition 2016, 11, :o1, 1478412000
- tz.transition 2017, 3, :o2, 1489302000
- tz.transition 2017, 11, :o1, 1509861600
- tz.transition 2018, 3, :o2, 1520751600
- tz.transition 2018, 11, :o1, 1541311200
- tz.transition 2019, 3, :o2, 1552201200
- tz.transition 2019, 11, :o1, 1572760800
- tz.transition 2020, 3, :o2, 1583650800
- tz.transition 2020, 11, :o1, 1604210400
- tz.transition 2021, 3, :o2, 1615705200
- tz.transition 2021, 11, :o1, 1636264800
- tz.transition 2022, 3, :o2, 1647154800
- tz.transition 2022, 11, :o1, 1667714400
- tz.transition 2023, 3, :o2, 1678604400
- tz.transition 2023, 11, :o1, 1699164000
- tz.transition 2024, 3, :o2, 1710054000
- tz.transition 2024, 11, :o1, 1730613600
- tz.transition 2025, 3, :o2, 1741503600
- tz.transition 2025, 11, :o1, 1762063200
- tz.transition 2026, 3, :o2, 1772953200
- tz.transition 2026, 11, :o1, 1793512800
- tz.transition 2027, 3, :o2, 1805007600
- tz.transition 2027, 11, :o1, 1825567200
- tz.transition 2028, 3, :o2, 1836457200
- tz.transition 2028, 11, :o1, 1857016800
- tz.transition 2029, 3, :o2, 1867906800
- tz.transition 2029, 11, :o1, 1888466400
- tz.transition 2030, 3, :o2, 1899356400
- tz.transition 2030, 11, :o1, 1919916000
- tz.transition 2031, 3, :o2, 1930806000
- tz.transition 2031, 11, :o1, 1951365600
- tz.transition 2032, 3, :o2, 1962860400
- tz.transition 2032, 11, :o1, 1983420000
- tz.transition 2033, 3, :o2, 1994310000
- tz.transition 2033, 11, :o1, 2014869600
- tz.transition 2034, 3, :o2, 2025759600
- tz.transition 2034, 11, :o1, 2046319200
- tz.transition 2035, 3, :o2, 2057209200
- tz.transition 2035, 11, :o1, 2077768800
- tz.transition 2036, 3, :o2, 2088658800
- tz.transition 2036, 11, :o1, 2109218400
- tz.transition 2037, 3, :o2, 2120108400
- tz.transition 2037, 11, :o1, 2140668000
- tz.transition 2038, 3, :o2, 59171923, 24
- tz.transition 2038, 11, :o1, 9862939, 4
- tz.transition 2039, 3, :o2, 59180659, 24
- tz.transition 2039, 11, :o1, 9864395, 4
- tz.transition 2040, 3, :o2, 59189395, 24
- tz.transition 2040, 11, :o1, 9865851, 4
- tz.transition 2041, 3, :o2, 59198131, 24
- tz.transition 2041, 11, :o1, 9867307, 4
- tz.transition 2042, 3, :o2, 59206867, 24
- tz.transition 2042, 11, :o1, 9868763, 4
- tz.transition 2043, 3, :o2, 59215603, 24
- tz.transition 2043, 11, :o1, 9870219, 4
- tz.transition 2044, 3, :o2, 59224507, 24
- tz.transition 2044, 11, :o1, 9871703, 4
- tz.transition 2045, 3, :o2, 59233243, 24
- tz.transition 2045, 11, :o1, 9873159, 4
- tz.transition 2046, 3, :o2, 59241979, 24
- tz.transition 2046, 11, :o1, 9874615, 4
- tz.transition 2047, 3, :o2, 59250715, 24
- tz.transition 2047, 11, :o1, 9876071, 4
- tz.transition 2048, 3, :o2, 59259451, 24
- tz.transition 2048, 11, :o1, 9877527, 4
- tz.transition 2049, 3, :o2, 59268355, 24
- tz.transition 2049, 11, :o1, 9879011, 4
- tz.transition 2050, 3, :o2, 59277091, 24
- tz.transition 2050, 11, :o1, 9880467, 4
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Phoenix.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Phoenix.rb
deleted file mode 100644
index b514e0c0f9..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Phoenix.rb
+++ /dev/null
@@ -1,30 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module Phoenix
- include TimezoneDefinition
-
- timezone 'America/Phoenix' do |tz|
- tz.offset :o0, -26898, 0, :LMT
- tz.offset :o1, -25200, 0, :MST
- tz.offset :o2, -25200, 3600, :MDT
- tz.offset :o3, -25200, 3600, :MWT
-
- tz.transition 1883, 11, :o1, 57819199, 24
- tz.transition 1918, 3, :o2, 19373471, 8
- tz.transition 1918, 10, :o1, 14531363, 6
- tz.transition 1919, 3, :o2, 19376383, 8
- tz.transition 1919, 10, :o1, 14533547, 6
- tz.transition 1942, 2, :o3, 19443199, 8
- tz.transition 1944, 1, :o1, 3500770681, 1440
- tz.transition 1944, 4, :o3, 3500901781, 1440
- tz.transition 1944, 10, :o1, 3501165241, 1440
- tz.transition 1967, 4, :o2, 19516887, 8
- tz.transition 1967, 10, :o1, 14638757, 6
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Regina.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Regina.rb
deleted file mode 100644
index ebdb68814a..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Regina.rb
+++ /dev/null
@@ -1,74 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module Regina
- include TimezoneDefinition
-
- timezone 'America/Regina' do |tz|
- tz.offset :o0, -25116, 0, :LMT
- tz.offset :o1, -25200, 0, :MST
- tz.offset :o2, -25200, 3600, :MDT
- tz.offset :o3, -25200, 3600, :MWT
- tz.offset :o4, -25200, 3600, :MPT
- tz.offset :o5, -21600, 0, :CST
-
- tz.transition 1905, 9, :o1, 17403046493, 7200
- tz.transition 1918, 4, :o2, 19373583, 8
- tz.transition 1918, 10, :o1, 14531387, 6
- tz.transition 1930, 5, :o2, 58226419, 24
- tz.transition 1930, 10, :o1, 9705019, 4
- tz.transition 1931, 5, :o2, 58235155, 24
- tz.transition 1931, 10, :o1, 9706475, 4
- tz.transition 1932, 5, :o2, 58243891, 24
- tz.transition 1932, 10, :o1, 9707931, 4
- tz.transition 1933, 5, :o2, 58252795, 24
- tz.transition 1933, 10, :o1, 9709387, 4
- tz.transition 1934, 5, :o2, 58261531, 24
- tz.transition 1934, 10, :o1, 9710871, 4
- tz.transition 1937, 4, :o2, 58287235, 24
- tz.transition 1937, 10, :o1, 9715267, 4
- tz.transition 1938, 4, :o2, 58295971, 24
- tz.transition 1938, 10, :o1, 9716695, 4
- tz.transition 1939, 4, :o2, 58304707, 24
- tz.transition 1939, 10, :o1, 9718179, 4
- tz.transition 1940, 4, :o2, 58313611, 24
- tz.transition 1940, 10, :o1, 9719663, 4
- tz.transition 1941, 4, :o2, 58322347, 24
- tz.transition 1941, 10, :o1, 9721119, 4
- tz.transition 1942, 2, :o3, 19443199, 8
- tz.transition 1945, 8, :o4, 58360379, 24
- tz.transition 1945, 9, :o1, 14590373, 6
- tz.transition 1946, 4, :o2, 19455399, 8
- tz.transition 1946, 10, :o1, 14592641, 6
- tz.transition 1947, 4, :o2, 19458423, 8
- tz.transition 1947, 9, :o1, 14594741, 6
- tz.transition 1948, 4, :o2, 19461335, 8
- tz.transition 1948, 9, :o1, 14596925, 6
- tz.transition 1949, 4, :o2, 19464247, 8
- tz.transition 1949, 9, :o1, 14599109, 6
- tz.transition 1950, 4, :o2, 19467215, 8
- tz.transition 1950, 9, :o1, 14601293, 6
- tz.transition 1951, 4, :o2, 19470127, 8
- tz.transition 1951, 9, :o1, 14603519, 6
- tz.transition 1952, 4, :o2, 19473039, 8
- tz.transition 1952, 9, :o1, 14605703, 6
- tz.transition 1953, 4, :o2, 19475951, 8
- tz.transition 1953, 9, :o1, 14607887, 6
- tz.transition 1954, 4, :o2, 19478863, 8
- tz.transition 1954, 9, :o1, 14610071, 6
- tz.transition 1955, 4, :o2, 19481775, 8
- tz.transition 1955, 9, :o1, 14612255, 6
- tz.transition 1956, 4, :o2, 19484743, 8
- tz.transition 1956, 9, :o1, 14614481, 6
- tz.transition 1957, 4, :o2, 19487655, 8
- tz.transition 1957, 9, :o1, 14616665, 6
- tz.transition 1959, 4, :o2, 19493479, 8
- tz.transition 1959, 10, :o1, 14621201, 6
- tz.transition 1960, 4, :o5, 19496391, 8
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Santiago.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Santiago.rb
deleted file mode 100644
index 0287c9ebc4..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Santiago.rb
+++ /dev/null
@@ -1,205 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module Santiago
- include TimezoneDefinition
-
- timezone 'America/Santiago' do |tz|
- tz.offset :o0, -16966, 0, :LMT
- tz.offset :o1, -16966, 0, :SMT
- tz.offset :o2, -18000, 0, :CLT
- tz.offset :o3, -14400, 0, :CLT
- tz.offset :o4, -18000, 3600, :CLST
- tz.offset :o5, -14400, 3600, :CLST
-
- tz.transition 1890, 1, :o1, 104171127683, 43200
- tz.transition 1910, 1, :o2, 104486660483, 43200
- tz.transition 1916, 7, :o1, 58105097, 24
- tz.transition 1918, 9, :o3, 104623388483, 43200
- tz.transition 1919, 7, :o1, 7266422, 3
- tz.transition 1927, 9, :o4, 104765386883, 43200
- tz.transition 1928, 4, :o2, 7276013, 3
- tz.transition 1928, 9, :o4, 58211777, 24
- tz.transition 1929, 4, :o2, 7277108, 3
- tz.transition 1929, 9, :o4, 58220537, 24
- tz.transition 1930, 4, :o2, 7278203, 3
- tz.transition 1930, 9, :o4, 58229297, 24
- tz.transition 1931, 4, :o2, 7279298, 3
- tz.transition 1931, 9, :o4, 58238057, 24
- tz.transition 1932, 4, :o2, 7280396, 3
- tz.transition 1932, 9, :o4, 58246841, 24
- tz.transition 1942, 6, :o2, 7291535, 3
- tz.transition 1942, 8, :o4, 58333745, 24
- tz.transition 1946, 9, :o2, 19456517, 8
- tz.transition 1947, 5, :o3, 58375865, 24
- tz.transition 1968, 11, :o5, 7320491, 3
- tz.transition 1969, 3, :o3, 19522485, 8
- tz.transition 1969, 11, :o5, 7321646, 3
- tz.transition 1970, 3, :o3, 7527600
- tz.transition 1970, 10, :o5, 24465600
- tz.transition 1971, 3, :o3, 37767600
- tz.transition 1971, 10, :o5, 55915200
- tz.transition 1972, 3, :o3, 69217200
- tz.transition 1972, 10, :o5, 87969600
- tz.transition 1973, 3, :o3, 100666800
- tz.transition 1973, 9, :o5, 118209600
- tz.transition 1974, 3, :o3, 132116400
- tz.transition 1974, 10, :o5, 150868800
- tz.transition 1975, 3, :o3, 163566000
- tz.transition 1975, 10, :o5, 182318400
- tz.transition 1976, 3, :o3, 195620400
- tz.transition 1976, 10, :o5, 213768000
- tz.transition 1977, 3, :o3, 227070000
- tz.transition 1977, 10, :o5, 245217600
- tz.transition 1978, 3, :o3, 258519600
- tz.transition 1978, 10, :o5, 277272000
- tz.transition 1979, 3, :o3, 289969200
- tz.transition 1979, 10, :o5, 308721600
- tz.transition 1980, 3, :o3, 321418800
- tz.transition 1980, 10, :o5, 340171200
- tz.transition 1981, 3, :o3, 353473200
- tz.transition 1981, 10, :o5, 371620800
- tz.transition 1982, 3, :o3, 384922800
- tz.transition 1982, 10, :o5, 403070400
- tz.transition 1983, 3, :o3, 416372400
- tz.transition 1983, 10, :o5, 434520000
- tz.transition 1984, 3, :o3, 447822000
- tz.transition 1984, 10, :o5, 466574400
- tz.transition 1985, 3, :o3, 479271600
- tz.transition 1985, 10, :o5, 498024000
- tz.transition 1986, 3, :o3, 510721200
- tz.transition 1986, 10, :o5, 529473600
- tz.transition 1987, 4, :o3, 545194800
- tz.transition 1987, 10, :o5, 560923200
- tz.transition 1988, 3, :o3, 574225200
- tz.transition 1988, 10, :o5, 591768000
- tz.transition 1989, 3, :o3, 605674800
- tz.transition 1989, 10, :o5, 624427200
- tz.transition 1990, 3, :o3, 637729200
- tz.transition 1990, 9, :o5, 653457600
- tz.transition 1991, 3, :o3, 668574000
- tz.transition 1991, 10, :o5, 687326400
- tz.transition 1992, 3, :o3, 700628400
- tz.transition 1992, 10, :o5, 718776000
- tz.transition 1993, 3, :o3, 732078000
- tz.transition 1993, 10, :o5, 750225600
- tz.transition 1994, 3, :o3, 763527600
- tz.transition 1994, 10, :o5, 781675200
- tz.transition 1995, 3, :o3, 794977200
- tz.transition 1995, 10, :o5, 813729600
- tz.transition 1996, 3, :o3, 826426800
- tz.transition 1996, 10, :o5, 845179200
- tz.transition 1997, 3, :o3, 859690800
- tz.transition 1997, 10, :o5, 876628800
- tz.transition 1998, 3, :o3, 889930800
- tz.transition 1998, 9, :o5, 906868800
- tz.transition 1999, 4, :o3, 923194800
- tz.transition 1999, 10, :o5, 939528000
- tz.transition 2000, 3, :o3, 952830000
- tz.transition 2000, 10, :o5, 971582400
- tz.transition 2001, 3, :o3, 984279600
- tz.transition 2001, 10, :o5, 1003032000
- tz.transition 2002, 3, :o3, 1015729200
- tz.transition 2002, 10, :o5, 1034481600
- tz.transition 2003, 3, :o3, 1047178800
- tz.transition 2003, 10, :o5, 1065931200
- tz.transition 2004, 3, :o3, 1079233200
- tz.transition 2004, 10, :o5, 1097380800
- tz.transition 2005, 3, :o3, 1110682800
- tz.transition 2005, 10, :o5, 1128830400
- tz.transition 2006, 3, :o3, 1142132400
- tz.transition 2006, 10, :o5, 1160884800
- tz.transition 2007, 3, :o3, 1173582000
- tz.transition 2007, 10, :o5, 1192334400
- tz.transition 2008, 3, :o3, 1206846000
- tz.transition 2008, 10, :o5, 1223784000
- tz.transition 2009, 3, :o3, 1237086000
- tz.transition 2009, 10, :o5, 1255233600
- tz.transition 2010, 3, :o3, 1268535600
- tz.transition 2010, 10, :o5, 1286683200
- tz.transition 2011, 3, :o3, 1299985200
- tz.transition 2011, 10, :o5, 1318132800
- tz.transition 2012, 3, :o3, 1331434800
- tz.transition 2012, 10, :o5, 1350187200
- tz.transition 2013, 3, :o3, 1362884400
- tz.transition 2013, 10, :o5, 1381636800
- tz.transition 2014, 3, :o3, 1394334000
- tz.transition 2014, 10, :o5, 1413086400
- tz.transition 2015, 3, :o3, 1426388400
- tz.transition 2015, 10, :o5, 1444536000
- tz.transition 2016, 3, :o3, 1457838000
- tz.transition 2016, 10, :o5, 1475985600
- tz.transition 2017, 3, :o3, 1489287600
- tz.transition 2017, 10, :o5, 1508040000
- tz.transition 2018, 3, :o3, 1520737200
- tz.transition 2018, 10, :o5, 1539489600
- tz.transition 2019, 3, :o3, 1552186800
- tz.transition 2019, 10, :o5, 1570939200
- tz.transition 2020, 3, :o3, 1584241200
- tz.transition 2020, 10, :o5, 1602388800
- tz.transition 2021, 3, :o3, 1615690800
- tz.transition 2021, 10, :o5, 1633838400
- tz.transition 2022, 3, :o3, 1647140400
- tz.transition 2022, 10, :o5, 1665288000
- tz.transition 2023, 3, :o3, 1678590000
- tz.transition 2023, 10, :o5, 1697342400
- tz.transition 2024, 3, :o3, 1710039600
- tz.transition 2024, 10, :o5, 1728792000
- tz.transition 2025, 3, :o3, 1741489200
- tz.transition 2025, 10, :o5, 1760241600
- tz.transition 2026, 3, :o3, 1773543600
- tz.transition 2026, 10, :o5, 1791691200
- tz.transition 2027, 3, :o3, 1804993200
- tz.transition 2027, 10, :o5, 1823140800
- tz.transition 2028, 3, :o3, 1836442800
- tz.transition 2028, 10, :o5, 1855195200
- tz.transition 2029, 3, :o3, 1867892400
- tz.transition 2029, 10, :o5, 1886644800
- tz.transition 2030, 3, :o3, 1899342000
- tz.transition 2030, 10, :o5, 1918094400
- tz.transition 2031, 3, :o3, 1930791600
- tz.transition 2031, 10, :o5, 1949544000
- tz.transition 2032, 3, :o3, 1962846000
- tz.transition 2032, 10, :o5, 1980993600
- tz.transition 2033, 3, :o3, 1994295600
- tz.transition 2033, 10, :o5, 2012443200
- tz.transition 2034, 3, :o3, 2025745200
- tz.transition 2034, 10, :o5, 2044497600
- tz.transition 2035, 3, :o3, 2057194800
- tz.transition 2035, 10, :o5, 2075947200
- tz.transition 2036, 3, :o3, 2088644400
- tz.transition 2036, 10, :o5, 2107396800
- tz.transition 2037, 3, :o3, 2120698800
- tz.transition 2037, 10, :o5, 2138846400
- tz.transition 2038, 3, :o3, 19723973, 8
- tz.transition 2038, 10, :o5, 7397120, 3
- tz.transition 2039, 3, :o3, 19726885, 8
- tz.transition 2039, 10, :o5, 7398212, 3
- tz.transition 2040, 3, :o3, 19729797, 8
- tz.transition 2040, 10, :o5, 7399325, 3
- tz.transition 2041, 3, :o3, 19732709, 8
- tz.transition 2041, 10, :o5, 7400417, 3
- tz.transition 2042, 3, :o3, 19735621, 8
- tz.transition 2042, 10, :o5, 7401509, 3
- tz.transition 2043, 3, :o3, 19738589, 8
- tz.transition 2043, 10, :o5, 7402601, 3
- tz.transition 2044, 3, :o3, 19741501, 8
- tz.transition 2044, 10, :o5, 7403693, 3
- tz.transition 2045, 3, :o3, 19744413, 8
- tz.transition 2045, 10, :o5, 7404806, 3
- tz.transition 2046, 3, :o3, 19747325, 8
- tz.transition 2046, 10, :o5, 7405898, 3
- tz.transition 2047, 3, :o3, 19750237, 8
- tz.transition 2047, 10, :o5, 7406990, 3
- tz.transition 2048, 3, :o3, 19753205, 8
- tz.transition 2048, 10, :o5, 7408082, 3
- tz.transition 2049, 3, :o3, 19756117, 8
- tz.transition 2049, 10, :o5, 7409174, 3
- tz.transition 2050, 3, :o3, 19759029, 8
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Sao_Paulo.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Sao_Paulo.rb
deleted file mode 100644
index 0524f81c04..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Sao_Paulo.rb
+++ /dev/null
@@ -1,171 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module Sao_Paulo
- include TimezoneDefinition
-
- timezone 'America/Sao_Paulo' do |tz|
- tz.offset :o0, -11188, 0, :LMT
- tz.offset :o1, -10800, 0, :BRT
- tz.offset :o2, -10800, 3600, :BRST
-
- tz.transition 1914, 1, :o1, 52274886397, 21600
- tz.transition 1931, 10, :o2, 29119417, 12
- tz.transition 1932, 4, :o1, 29121583, 12
- tz.transition 1932, 10, :o2, 19415869, 8
- tz.transition 1933, 4, :o1, 29125963, 12
- tz.transition 1949, 12, :o2, 19466013, 8
- tz.transition 1950, 4, :o1, 19467101, 8
- tz.transition 1950, 12, :o2, 19468933, 8
- tz.transition 1951, 4, :o1, 29204851, 12
- tz.transition 1951, 12, :o2, 19471853, 8
- tz.transition 1952, 4, :o1, 29209243, 12
- tz.transition 1952, 12, :o2, 19474781, 8
- tz.transition 1953, 3, :o1, 29213251, 12
- tz.transition 1963, 10, :o2, 19506605, 8
- tz.transition 1964, 3, :o1, 29261467, 12
- tz.transition 1965, 1, :o2, 19510333, 8
- tz.transition 1965, 3, :o1, 29266207, 12
- tz.transition 1965, 12, :o2, 19512765, 8
- tz.transition 1966, 3, :o1, 29270227, 12
- tz.transition 1966, 11, :o2, 19515445, 8
- tz.transition 1967, 3, :o1, 29274607, 12
- tz.transition 1967, 11, :o2, 19518365, 8
- tz.transition 1968, 3, :o1, 29278999, 12
- tz.transition 1985, 11, :o2, 499748400
- tz.transition 1986, 3, :o1, 511236000
- tz.transition 1986, 10, :o2, 530593200
- tz.transition 1987, 2, :o1, 540266400
- tz.transition 1987, 10, :o2, 562129200
- tz.transition 1988, 2, :o1, 571197600
- tz.transition 1988, 10, :o2, 592974000
- tz.transition 1989, 1, :o1, 602042400
- tz.transition 1989, 10, :o2, 624423600
- tz.transition 1990, 2, :o1, 634701600
- tz.transition 1990, 10, :o2, 656478000
- tz.transition 1991, 2, :o1, 666756000
- tz.transition 1991, 10, :o2, 687927600
- tz.transition 1992, 2, :o1, 697600800
- tz.transition 1992, 10, :o2, 719982000
- tz.transition 1993, 1, :o1, 728445600
- tz.transition 1993, 10, :o2, 750826800
- tz.transition 1994, 2, :o1, 761709600
- tz.transition 1994, 10, :o2, 782276400
- tz.transition 1995, 2, :o1, 793159200
- tz.transition 1995, 10, :o2, 813726000
- tz.transition 1996, 2, :o1, 824004000
- tz.transition 1996, 10, :o2, 844570800
- tz.transition 1997, 2, :o1, 856058400
- tz.transition 1997, 10, :o2, 876106800
- tz.transition 1998, 3, :o1, 888717600
- tz.transition 1998, 10, :o2, 908074800
- tz.transition 1999, 2, :o1, 919562400
- tz.transition 1999, 10, :o2, 938919600
- tz.transition 2000, 2, :o1, 951616800
- tz.transition 2000, 10, :o2, 970974000
- tz.transition 2001, 2, :o1, 982461600
- tz.transition 2001, 10, :o2, 1003028400
- tz.transition 2002, 2, :o1, 1013911200
- tz.transition 2002, 11, :o2, 1036292400
- tz.transition 2003, 2, :o1, 1045360800
- tz.transition 2003, 10, :o2, 1066532400
- tz.transition 2004, 2, :o1, 1076810400
- tz.transition 2004, 11, :o2, 1099364400
- tz.transition 2005, 2, :o1, 1108864800
- tz.transition 2005, 10, :o2, 1129431600
- tz.transition 2006, 2, :o1, 1140314400
- tz.transition 2006, 11, :o2, 1162695600
- tz.transition 2007, 2, :o1, 1172368800
- tz.transition 2007, 10, :o2, 1192330800
- tz.transition 2008, 2, :o1, 1203213600
- tz.transition 2008, 10, :o2, 1224385200
- tz.transition 2009, 2, :o1, 1234663200
- tz.transition 2009, 10, :o2, 1255834800
- tz.transition 2010, 2, :o1, 1266717600
- tz.transition 2010, 10, :o2, 1287284400
- tz.transition 2011, 2, :o1, 1298167200
- tz.transition 2011, 10, :o2, 1318734000
- tz.transition 2012, 2, :o1, 1330221600
- tz.transition 2012, 10, :o2, 1350788400
- tz.transition 2013, 2, :o1, 1361066400
- tz.transition 2013, 10, :o2, 1382238000
- tz.transition 2014, 2, :o1, 1392516000
- tz.transition 2014, 10, :o2, 1413687600
- tz.transition 2015, 2, :o1, 1424570400
- tz.transition 2015, 10, :o2, 1445137200
- tz.transition 2016, 2, :o1, 1456020000
- tz.transition 2016, 10, :o2, 1476586800
- tz.transition 2017, 2, :o1, 1487469600
- tz.transition 2017, 10, :o2, 1508036400
- tz.transition 2018, 2, :o1, 1518919200
- tz.transition 2018, 10, :o2, 1540090800
- tz.transition 2019, 2, :o1, 1550368800
- tz.transition 2019, 10, :o2, 1571540400
- tz.transition 2020, 2, :o1, 1581818400
- tz.transition 2020, 10, :o2, 1602990000
- tz.transition 2021, 2, :o1, 1613872800
- tz.transition 2021, 10, :o2, 1634439600
- tz.transition 2022, 2, :o1, 1645322400
- tz.transition 2022, 10, :o2, 1665889200
- tz.transition 2023, 2, :o1, 1677376800
- tz.transition 2023, 10, :o2, 1697338800
- tz.transition 2024, 2, :o1, 1708221600
- tz.transition 2024, 10, :o2, 1729393200
- tz.transition 2025, 2, :o1, 1739671200
- tz.transition 2025, 10, :o2, 1760842800
- tz.transition 2026, 2, :o1, 1771725600
- tz.transition 2026, 10, :o2, 1792292400
- tz.transition 2027, 2, :o1, 1803175200
- tz.transition 2027, 10, :o2, 1823742000
- tz.transition 2028, 2, :o1, 1834624800
- tz.transition 2028, 10, :o2, 1855191600
- tz.transition 2029, 2, :o1, 1866074400
- tz.transition 2029, 10, :o2, 1887246000
- tz.transition 2030, 2, :o1, 1897524000
- tz.transition 2030, 10, :o2, 1918695600
- tz.transition 2031, 2, :o1, 1928973600
- tz.transition 2031, 10, :o2, 1950145200
- tz.transition 2032, 2, :o1, 1960423200
- tz.transition 2032, 10, :o2, 1981594800
- tz.transition 2033, 2, :o1, 1992477600
- tz.transition 2033, 10, :o2, 2013044400
- tz.transition 2034, 2, :o1, 2024532000
- tz.transition 2034, 10, :o2, 2044494000
- tz.transition 2035, 2, :o1, 2055376800
- tz.transition 2035, 10, :o2, 2076548400
- tz.transition 2036, 2, :o1, 2086826400
- tz.transition 2036, 10, :o2, 2107998000
- tz.transition 2037, 2, :o1, 2118880800
- tz.transition 2037, 10, :o2, 2139447600
- tz.transition 2038, 2, :o1, 29585707, 12
- tz.transition 2038, 10, :o2, 19725709, 8
- tz.transition 2039, 2, :o1, 29590075, 12
- tz.transition 2039, 10, :o2, 19728621, 8
- tz.transition 2040, 2, :o1, 29594443, 12
- tz.transition 2040, 10, :o2, 19731589, 8
- tz.transition 2041, 2, :o1, 29598811, 12
- tz.transition 2041, 10, :o2, 19734501, 8
- tz.transition 2042, 2, :o1, 29603179, 12
- tz.transition 2042, 10, :o2, 19737413, 8
- tz.transition 2043, 2, :o1, 29607547, 12
- tz.transition 2043, 10, :o2, 19740325, 8
- tz.transition 2044, 2, :o1, 29611999, 12
- tz.transition 2044, 10, :o2, 19743237, 8
- tz.transition 2045, 2, :o1, 29616367, 12
- tz.transition 2045, 10, :o2, 19746149, 8
- tz.transition 2046, 2, :o1, 29620735, 12
- tz.transition 2046, 10, :o2, 19749117, 8
- tz.transition 2047, 2, :o1, 29625103, 12
- tz.transition 2047, 10, :o2, 19752029, 8
- tz.transition 2048, 2, :o1, 29629471, 12
- tz.transition 2048, 10, :o2, 19754941, 8
- tz.transition 2049, 2, :o1, 29633923, 12
- tz.transition 2049, 10, :o2, 19757853, 8
- tz.transition 2050, 2, :o1, 29638291, 12
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/St_Johns.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/St_Johns.rb
deleted file mode 100644
index e4a3599d35..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/St_Johns.rb
+++ /dev/null
@@ -1,288 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module St_Johns
- include TimezoneDefinition
-
- timezone 'America/St_Johns' do |tz|
- tz.offset :o0, -12652, 0, :LMT
- tz.offset :o1, -12652, 0, :NST
- tz.offset :o2, -12652, 3600, :NDT
- tz.offset :o3, -12600, 0, :NST
- tz.offset :o4, -12600, 3600, :NDT
- tz.offset :o5, -12600, 3600, :NWT
- tz.offset :o6, -12600, 3600, :NPT
- tz.offset :o7, -12600, 7200, :NDDT
-
- tz.transition 1884, 1, :o1, 52038215563, 21600
- tz.transition 1917, 4, :o2, 52300657363, 21600
- tz.transition 1917, 9, :o1, 52304155663, 21600
- tz.transition 1918, 4, :o2, 52308670963, 21600
- tz.transition 1918, 10, :o1, 52312990063, 21600
- tz.transition 1919, 5, :o2, 52317027463, 21600
- tz.transition 1919, 8, :o1, 52319164963, 21600
- tz.transition 1920, 5, :o2, 52324868263, 21600
- tz.transition 1920, 11, :o1, 52328798563, 21600
- tz.transition 1921, 5, :o2, 52332730663, 21600
- tz.transition 1921, 10, :o1, 52336660963, 21600
- tz.transition 1922, 5, :o2, 52340744263, 21600
- tz.transition 1922, 10, :o1, 52344523363, 21600
- tz.transition 1923, 5, :o2, 52348606663, 21600
- tz.transition 1923, 10, :o1, 52352385763, 21600
- tz.transition 1924, 5, :o2, 52356469063, 21600
- tz.transition 1924, 10, :o1, 52360248163, 21600
- tz.transition 1925, 5, :o2, 52364331463, 21600
- tz.transition 1925, 10, :o1, 52368110563, 21600
- tz.transition 1926, 5, :o2, 52372193863, 21600
- tz.transition 1926, 11, :o1, 52376124163, 21600
- tz.transition 1927, 5, :o2, 52380056263, 21600
- tz.transition 1927, 10, :o1, 52383986563, 21600
- tz.transition 1928, 5, :o2, 52388069863, 21600
- tz.transition 1928, 10, :o1, 52391848963, 21600
- tz.transition 1929, 5, :o2, 52395932263, 21600
- tz.transition 1929, 10, :o1, 52399711363, 21600
- tz.transition 1930, 5, :o2, 52403794663, 21600
- tz.transition 1930, 10, :o1, 52407573763, 21600
- tz.transition 1931, 5, :o2, 52411657063, 21600
- tz.transition 1931, 10, :o1, 52415436163, 21600
- tz.transition 1932, 5, :o2, 52419519463, 21600
- tz.transition 1932, 10, :o1, 52423449763, 21600
- tz.transition 1933, 5, :o2, 52427533063, 21600
- tz.transition 1933, 10, :o1, 52431312163, 21600
- tz.transition 1934, 5, :o2, 52435395463, 21600
- tz.transition 1934, 10, :o1, 52439174563, 21600
- tz.transition 1935, 3, :o3, 52442459563, 21600
- tz.transition 1935, 5, :o4, 116540573, 48
- tz.transition 1935, 10, :o3, 38849657, 16
- tz.transition 1936, 5, :o4, 116558383, 48
- tz.transition 1936, 10, :o3, 116565437, 48
- tz.transition 1937, 5, :o4, 116575855, 48
- tz.transition 1937, 10, :o3, 116582909, 48
- tz.transition 1938, 5, :o4, 116593327, 48
- tz.transition 1938, 10, :o3, 116600381, 48
- tz.transition 1939, 5, :o4, 116611135, 48
- tz.transition 1939, 10, :o3, 116617853, 48
- tz.transition 1940, 5, :o4, 116628607, 48
- tz.transition 1940, 10, :o3, 116635661, 48
- tz.transition 1941, 5, :o4, 116646079, 48
- tz.transition 1941, 10, :o3, 116653133, 48
- tz.transition 1942, 5, :o5, 116663551, 48
- tz.transition 1945, 8, :o6, 58360379, 24
- tz.transition 1945, 9, :o3, 38907659, 16
- tz.transition 1946, 5, :o4, 116733731, 48
- tz.transition 1946, 10, :o3, 38913595, 16
- tz.transition 1947, 5, :o4, 116751203, 48
- tz.transition 1947, 10, :o3, 38919419, 16
- tz.transition 1948, 5, :o4, 116768675, 48
- tz.transition 1948, 10, :o3, 38925243, 16
- tz.transition 1949, 5, :o4, 116786147, 48
- tz.transition 1949, 10, :o3, 38931067, 16
- tz.transition 1950, 5, :o4, 116803955, 48
- tz.transition 1950, 10, :o3, 38937003, 16
- tz.transition 1951, 4, :o4, 116820755, 48
- tz.transition 1951, 9, :o3, 38942715, 16
- tz.transition 1952, 4, :o4, 116838227, 48
- tz.transition 1952, 9, :o3, 38948539, 16
- tz.transition 1953, 4, :o4, 116855699, 48
- tz.transition 1953, 9, :o3, 38954363, 16
- tz.transition 1954, 4, :o4, 116873171, 48
- tz.transition 1954, 9, :o3, 38960187, 16
- tz.transition 1955, 4, :o4, 116890643, 48
- tz.transition 1955, 9, :o3, 38966011, 16
- tz.transition 1956, 4, :o4, 116908451, 48
- tz.transition 1956, 9, :o3, 38971947, 16
- tz.transition 1957, 4, :o4, 116925923, 48
- tz.transition 1957, 9, :o3, 38977771, 16
- tz.transition 1958, 4, :o4, 116943395, 48
- tz.transition 1958, 9, :o3, 38983595, 16
- tz.transition 1959, 4, :o4, 116960867, 48
- tz.transition 1959, 9, :o3, 38989419, 16
- tz.transition 1960, 4, :o4, 116978339, 48
- tz.transition 1960, 10, :o3, 38995803, 16
- tz.transition 1961, 4, :o4, 116996147, 48
- tz.transition 1961, 10, :o3, 39001627, 16
- tz.transition 1962, 4, :o4, 117013619, 48
- tz.transition 1962, 10, :o3, 39007451, 16
- tz.transition 1963, 4, :o4, 117031091, 48
- tz.transition 1963, 10, :o3, 39013275, 16
- tz.transition 1964, 4, :o4, 117048563, 48
- tz.transition 1964, 10, :o3, 39019099, 16
- tz.transition 1965, 4, :o4, 117066035, 48
- tz.transition 1965, 10, :o3, 39025035, 16
- tz.transition 1966, 4, :o4, 117083507, 48
- tz.transition 1966, 10, :o3, 39030859, 16
- tz.transition 1967, 4, :o4, 117101315, 48
- tz.transition 1967, 10, :o3, 39036683, 16
- tz.transition 1968, 4, :o4, 117118787, 48
- tz.transition 1968, 10, :o3, 39042507, 16
- tz.transition 1969, 4, :o4, 117136259, 48
- tz.transition 1969, 10, :o3, 39048331, 16
- tz.transition 1970, 4, :o4, 9955800
- tz.transition 1970, 10, :o3, 25677000
- tz.transition 1971, 4, :o4, 41405400
- tz.transition 1971, 10, :o3, 57731400
- tz.transition 1972, 4, :o4, 73459800
- tz.transition 1972, 10, :o3, 89181000
- tz.transition 1973, 4, :o4, 104909400
- tz.transition 1973, 10, :o3, 120630600
- tz.transition 1974, 4, :o4, 136359000
- tz.transition 1974, 10, :o3, 152080200
- tz.transition 1975, 4, :o4, 167808600
- tz.transition 1975, 10, :o3, 183529800
- tz.transition 1976, 4, :o4, 199258200
- tz.transition 1976, 10, :o3, 215584200
- tz.transition 1977, 4, :o4, 230707800
- tz.transition 1977, 10, :o3, 247033800
- tz.transition 1978, 4, :o4, 262762200
- tz.transition 1978, 10, :o3, 278483400
- tz.transition 1979, 4, :o4, 294211800
- tz.transition 1979, 10, :o3, 309933000
- tz.transition 1980, 4, :o4, 325661400
- tz.transition 1980, 10, :o3, 341382600
- tz.transition 1981, 4, :o4, 357111000
- tz.transition 1981, 10, :o3, 372832200
- tz.transition 1982, 4, :o4, 388560600
- tz.transition 1982, 10, :o3, 404886600
- tz.transition 1983, 4, :o4, 420010200
- tz.transition 1983, 10, :o3, 436336200
- tz.transition 1984, 4, :o4, 452064600
- tz.transition 1984, 10, :o3, 467785800
- tz.transition 1985, 4, :o4, 483514200
- tz.transition 1985, 10, :o3, 499235400
- tz.transition 1986, 4, :o4, 514963800
- tz.transition 1986, 10, :o3, 530685000
- tz.transition 1987, 4, :o4, 544591860
- tz.transition 1987, 10, :o3, 562127460
- tz.transition 1988, 4, :o7, 576041460
- tz.transition 1988, 10, :o3, 594178260
- tz.transition 1989, 4, :o4, 607491060
- tz.transition 1989, 10, :o3, 625631460
- tz.transition 1990, 4, :o4, 638940660
- tz.transition 1990, 10, :o3, 657081060
- tz.transition 1991, 4, :o4, 670995060
- tz.transition 1991, 10, :o3, 688530660
- tz.transition 1992, 4, :o4, 702444660
- tz.transition 1992, 10, :o3, 719980260
- tz.transition 1993, 4, :o4, 733894260
- tz.transition 1993, 10, :o3, 752034660
- tz.transition 1994, 4, :o4, 765343860
- tz.transition 1994, 10, :o3, 783484260
- tz.transition 1995, 4, :o4, 796793460
- tz.transition 1995, 10, :o3, 814933860
- tz.transition 1996, 4, :o4, 828847860
- tz.transition 1996, 10, :o3, 846383460
- tz.transition 1997, 4, :o4, 860297460
- tz.transition 1997, 10, :o3, 877833060
- tz.transition 1998, 4, :o4, 891747060
- tz.transition 1998, 10, :o3, 909282660
- tz.transition 1999, 4, :o4, 923196660
- tz.transition 1999, 10, :o3, 941337060
- tz.transition 2000, 4, :o4, 954646260
- tz.transition 2000, 10, :o3, 972786660
- tz.transition 2001, 4, :o4, 986095860
- tz.transition 2001, 10, :o3, 1004236260
- tz.transition 2002, 4, :o4, 1018150260
- tz.transition 2002, 10, :o3, 1035685860
- tz.transition 2003, 4, :o4, 1049599860
- tz.transition 2003, 10, :o3, 1067135460
- tz.transition 2004, 4, :o4, 1081049460
- tz.transition 2004, 10, :o3, 1099189860
- tz.transition 2005, 4, :o4, 1112499060
- tz.transition 2005, 10, :o3, 1130639460
- tz.transition 2006, 4, :o4, 1143948660
- tz.transition 2006, 10, :o3, 1162089060
- tz.transition 2007, 3, :o4, 1173583860
- tz.transition 2007, 11, :o3, 1194143460
- tz.transition 2008, 3, :o4, 1205033460
- tz.transition 2008, 11, :o3, 1225593060
- tz.transition 2009, 3, :o4, 1236483060
- tz.transition 2009, 11, :o3, 1257042660
- tz.transition 2010, 3, :o4, 1268537460
- tz.transition 2010, 11, :o3, 1289097060
- tz.transition 2011, 3, :o4, 1299987060
- tz.transition 2011, 11, :o3, 1320546660
- tz.transition 2012, 3, :o4, 1331436660
- tz.transition 2012, 11, :o3, 1351996260
- tz.transition 2013, 3, :o4, 1362886260
- tz.transition 2013, 11, :o3, 1383445860
- tz.transition 2014, 3, :o4, 1394335860
- tz.transition 2014, 11, :o3, 1414895460
- tz.transition 2015, 3, :o4, 1425785460
- tz.transition 2015, 11, :o3, 1446345060
- tz.transition 2016, 3, :o4, 1457839860
- tz.transition 2016, 11, :o3, 1478399460
- tz.transition 2017, 3, :o4, 1489289460
- tz.transition 2017, 11, :o3, 1509849060
- tz.transition 2018, 3, :o4, 1520739060
- tz.transition 2018, 11, :o3, 1541298660
- tz.transition 2019, 3, :o4, 1552188660
- tz.transition 2019, 11, :o3, 1572748260
- tz.transition 2020, 3, :o4, 1583638260
- tz.transition 2020, 11, :o3, 1604197860
- tz.transition 2021, 3, :o4, 1615692660
- tz.transition 2021, 11, :o3, 1636252260
- tz.transition 2022, 3, :o4, 1647142260
- tz.transition 2022, 11, :o3, 1667701860
- tz.transition 2023, 3, :o4, 1678591860
- tz.transition 2023, 11, :o3, 1699151460
- tz.transition 2024, 3, :o4, 1710041460
- tz.transition 2024, 11, :o3, 1730601060
- tz.transition 2025, 3, :o4, 1741491060
- tz.transition 2025, 11, :o3, 1762050660
- tz.transition 2026, 3, :o4, 1772940660
- tz.transition 2026, 11, :o3, 1793500260
- tz.transition 2027, 3, :o4, 1804995060
- tz.transition 2027, 11, :o3, 1825554660
- tz.transition 2028, 3, :o4, 1836444660
- tz.transition 2028, 11, :o3, 1857004260
- tz.transition 2029, 3, :o4, 1867894260
- tz.transition 2029, 11, :o3, 1888453860
- tz.transition 2030, 3, :o4, 1899343860
- tz.transition 2030, 11, :o3, 1919903460
- tz.transition 2031, 3, :o4, 1930793460
- tz.transition 2031, 11, :o3, 1951353060
- tz.transition 2032, 3, :o4, 1962847860
- tz.transition 2032, 11, :o3, 1983407460
- tz.transition 2033, 3, :o4, 1994297460
- tz.transition 2033, 11, :o3, 2014857060
- tz.transition 2034, 3, :o4, 2025747060
- tz.transition 2034, 11, :o3, 2046306660
- tz.transition 2035, 3, :o4, 2057196660
- tz.transition 2035, 11, :o3, 2077756260
- tz.transition 2036, 3, :o4, 2088646260
- tz.transition 2036, 11, :o3, 2109205860
- tz.transition 2037, 3, :o4, 2120095860
- tz.transition 2037, 11, :o3, 2140655460
- tz.transition 2038, 3, :o4, 3550315171, 1440
- tz.transition 2038, 11, :o3, 3550657831, 1440
- tz.transition 2039, 3, :o4, 3550839331, 1440
- tz.transition 2039, 11, :o3, 3551181991, 1440
- tz.transition 2040, 3, :o4, 3551363491, 1440
- tz.transition 2040, 11, :o3, 3551706151, 1440
- tz.transition 2041, 3, :o4, 3551887651, 1440
- tz.transition 2041, 11, :o3, 3552230311, 1440
- tz.transition 2042, 3, :o4, 3552411811, 1440
- tz.transition 2042, 11, :o3, 3552754471, 1440
- tz.transition 2043, 3, :o4, 3552935971, 1440
- tz.transition 2043, 11, :o3, 3553278631, 1440
- tz.transition 2044, 3, :o4, 3553470211, 1440
- tz.transition 2044, 11, :o3, 3553812871, 1440
- tz.transition 2045, 3, :o4, 3553994371, 1440
- tz.transition 2045, 11, :o3, 3554337031, 1440
- tz.transition 2046, 3, :o4, 3554518531, 1440
- tz.transition 2046, 11, :o3, 3554861191, 1440
- tz.transition 2047, 3, :o4, 3555042691, 1440
- tz.transition 2047, 11, :o3, 3555385351, 1440
- tz.transition 2048, 3, :o4, 3555566851, 1440
- tz.transition 2048, 11, :o3, 3555909511, 1440
- tz.transition 2049, 3, :o4, 3556101091, 1440
- tz.transition 2049, 11, :o3, 3556443751, 1440
- tz.transition 2050, 3, :o4, 3556625251, 1440
- tz.transition 2050, 11, :o3, 3556967911, 1440
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Tijuana.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Tijuana.rb
deleted file mode 100644
index 423059da46..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/America/Tijuana.rb
+++ /dev/null
@@ -1,196 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module America
- module Tijuana
- include TimezoneDefinition
-
- timezone 'America/Tijuana' do |tz|
- tz.offset :o0, -28084, 0, :LMT
- tz.offset :o1, -25200, 0, :MST
- tz.offset :o2, -28800, 0, :PST
- tz.offset :o3, -28800, 3600, :PDT
- tz.offset :o4, -28800, 3600, :PWT
- tz.offset :o5, -28800, 3600, :PPT
-
- tz.transition 1922, 1, :o1, 14538335, 6
- tz.transition 1924, 1, :o2, 58170859, 24
- tz.transition 1927, 6, :o1, 58201027, 24
- tz.transition 1930, 11, :o2, 58231099, 24
- tz.transition 1931, 4, :o3, 14558597, 6
- tz.transition 1931, 9, :o2, 58238755, 24
- tz.transition 1942, 4, :o4, 14582843, 6
- tz.transition 1945, 8, :o5, 58360379, 24
- tz.transition 1945, 11, :o2, 58362523, 24
- tz.transition 1948, 4, :o3, 14595881, 6
- tz.transition 1949, 1, :o2, 58390339, 24
- tz.transition 1954, 4, :o3, 29218295, 12
- tz.transition 1954, 9, :o2, 19480095, 8
- tz.transition 1955, 4, :o3, 29222663, 12
- tz.transition 1955, 9, :o2, 19483007, 8
- tz.transition 1956, 4, :o3, 29227115, 12
- tz.transition 1956, 9, :o2, 19485975, 8
- tz.transition 1957, 4, :o3, 29231483, 12
- tz.transition 1957, 9, :o2, 19488887, 8
- tz.transition 1958, 4, :o3, 29235851, 12
- tz.transition 1958, 9, :o2, 19491799, 8
- tz.transition 1959, 4, :o3, 29240219, 12
- tz.transition 1959, 9, :o2, 19494711, 8
- tz.transition 1960, 4, :o3, 29244587, 12
- tz.transition 1960, 9, :o2, 19497623, 8
- tz.transition 1976, 4, :o3, 199274400
- tz.transition 1976, 10, :o2, 215600400
- tz.transition 1977, 4, :o3, 230724000
- tz.transition 1977, 10, :o2, 247050000
- tz.transition 1978, 4, :o3, 262778400
- tz.transition 1978, 10, :o2, 278499600
- tz.transition 1979, 4, :o3, 294228000
- tz.transition 1979, 10, :o2, 309949200
- tz.transition 1980, 4, :o3, 325677600
- tz.transition 1980, 10, :o2, 341398800
- tz.transition 1981, 4, :o3, 357127200
- tz.transition 1981, 10, :o2, 372848400
- tz.transition 1982, 4, :o3, 388576800
- tz.transition 1982, 10, :o2, 404902800
- tz.transition 1983, 4, :o3, 420026400
- tz.transition 1983, 10, :o2, 436352400
- tz.transition 1984, 4, :o3, 452080800
- tz.transition 1984, 10, :o2, 467802000
- tz.transition 1985, 4, :o3, 483530400
- tz.transition 1985, 10, :o2, 499251600
- tz.transition 1986, 4, :o3, 514980000
- tz.transition 1986, 10, :o2, 530701200
- tz.transition 1987, 4, :o3, 544615200
- tz.transition 1987, 10, :o2, 562150800
- tz.transition 1988, 4, :o3, 576064800
- tz.transition 1988, 10, :o2, 594205200
- tz.transition 1989, 4, :o3, 607514400
- tz.transition 1989, 10, :o2, 625654800
- tz.transition 1990, 4, :o3, 638964000
- tz.transition 1990, 10, :o2, 657104400
- tz.transition 1991, 4, :o3, 671018400
- tz.transition 1991, 10, :o2, 688554000
- tz.transition 1992, 4, :o3, 702468000
- tz.transition 1992, 10, :o2, 720003600
- tz.transition 1993, 4, :o3, 733917600
- tz.transition 1993, 10, :o2, 752058000
- tz.transition 1994, 4, :o3, 765367200
- tz.transition 1994, 10, :o2, 783507600
- tz.transition 1995, 4, :o3, 796816800
- tz.transition 1995, 10, :o2, 814957200
- tz.transition 1996, 4, :o3, 828871200
- tz.transition 1996, 10, :o2, 846406800
- tz.transition 1997, 4, :o3, 860320800
- tz.transition 1997, 10, :o2, 877856400
- tz.transition 1998, 4, :o3, 891770400
- tz.transition 1998, 10, :o2, 909306000
- tz.transition 1999, 4, :o3, 923220000
- tz.transition 1999, 10, :o2, 941360400
- tz.transition 2000, 4, :o3, 954669600
- tz.transition 2000, 10, :o2, 972810000
- tz.transition 2001, 4, :o3, 986119200
- tz.transition 2001, 10, :o2, 1004259600
- tz.transition 2002, 4, :o3, 1018173600
- tz.transition 2002, 10, :o2, 1035709200
- tz.transition 2003, 4, :o3, 1049623200
- tz.transition 2003, 10, :o2, 1067158800
- tz.transition 2004, 4, :o3, 1081072800
- tz.transition 2004, 10, :o2, 1099213200
- tz.transition 2005, 4, :o3, 1112522400
- tz.transition 2005, 10, :o2, 1130662800
- tz.transition 2006, 4, :o3, 1143972000
- tz.transition 2006, 10, :o2, 1162112400
- tz.transition 2007, 4, :o3, 1175421600
- tz.transition 2007, 10, :o2, 1193562000
- tz.transition 2008, 4, :o3, 1207476000
- tz.transition 2008, 10, :o2, 1225011600
- tz.transition 2009, 4, :o3, 1238925600
- tz.transition 2009, 10, :o2, 1256461200
- tz.transition 2010, 4, :o3, 1270375200
- tz.transition 2010, 10, :o2, 1288515600
- tz.transition 2011, 4, :o3, 1301824800
- tz.transition 2011, 10, :o2, 1319965200
- tz.transition 2012, 4, :o3, 1333274400
- tz.transition 2012, 10, :o2, 1351414800
- tz.transition 2013, 4, :o3, 1365328800
- tz.transition 2013, 10, :o2, 1382864400
- tz.transition 2014, 4, :o3, 1396778400
- tz.transition 2014, 10, :o2, 1414314000
- tz.transition 2015, 4, :o3, 1428228000
- tz.transition 2015, 10, :o2, 1445763600
- tz.transition 2016, 4, :o3, 1459677600
- tz.transition 2016, 10, :o2, 1477818000
- tz.transition 2017, 4, :o3, 1491127200
- tz.transition 2017, 10, :o2, 1509267600
- tz.transition 2018, 4, :o3, 1522576800
- tz.transition 2018, 10, :o2, 1540717200
- tz.transition 2019, 4, :o3, 1554631200
- tz.transition 2019, 10, :o2, 1572166800
- tz.transition 2020, 4, :o3, 1586080800
- tz.transition 2020, 10, :o2, 1603616400
- tz.transition 2021, 4, :o3, 1617530400
- tz.transition 2021, 10, :o2, 1635670800
- tz.transition 2022, 4, :o3, 1648980000
- tz.transition 2022, 10, :o2, 1667120400
- tz.transition 2023, 4, :o3, 1680429600
- tz.transition 2023, 10, :o2, 1698570000
- tz.transition 2024, 4, :o3, 1712484000
- tz.transition 2024, 10, :o2, 1730019600
- tz.transition 2025, 4, :o3, 1743933600
- tz.transition 2025, 10, :o2, 1761469200
- tz.transition 2026, 4, :o3, 1775383200
- tz.transition 2026, 10, :o2, 1792918800
- tz.transition 2027, 4, :o3, 1806832800
- tz.transition 2027, 10, :o2, 1824973200
- tz.transition 2028, 4, :o3, 1838282400
- tz.transition 2028, 10, :o2, 1856422800
- tz.transition 2029, 4, :o3, 1869732000
- tz.transition 2029, 10, :o2, 1887872400
- tz.transition 2030, 4, :o3, 1901786400
- tz.transition 2030, 10, :o2, 1919322000
- tz.transition 2031, 4, :o3, 1933236000
- tz.transition 2031, 10, :o2, 1950771600
- tz.transition 2032, 4, :o3, 1964685600
- tz.transition 2032, 10, :o2, 1982826000
- tz.transition 2033, 4, :o3, 1996135200
- tz.transition 2033, 10, :o2, 2014275600
- tz.transition 2034, 4, :o3, 2027584800
- tz.transition 2034, 10, :o2, 2045725200
- tz.transition 2035, 4, :o3, 2059034400
- tz.transition 2035, 10, :o2, 2077174800
- tz.transition 2036, 4, :o3, 2091088800
- tz.transition 2036, 10, :o2, 2108624400
- tz.transition 2037, 4, :o3, 2122538400
- tz.transition 2037, 10, :o2, 2140074000
- tz.transition 2038, 4, :o3, 29586215, 12
- tz.transition 2038, 10, :o2, 19725823, 8
- tz.transition 2039, 4, :o3, 29590583, 12
- tz.transition 2039, 10, :o2, 19728735, 8
- tz.transition 2040, 4, :o3, 29594951, 12
- tz.transition 2040, 10, :o2, 19731647, 8
- tz.transition 2041, 4, :o3, 29599403, 12
- tz.transition 2041, 10, :o2, 19734559, 8
- tz.transition 2042, 4, :o3, 29603771, 12
- tz.transition 2042, 10, :o2, 19737471, 8
- tz.transition 2043, 4, :o3, 29608139, 12
- tz.transition 2043, 10, :o2, 19740383, 8
- tz.transition 2044, 4, :o3, 29612507, 12
- tz.transition 2044, 10, :o2, 19743351, 8
- tz.transition 2045, 4, :o3, 29616875, 12
- tz.transition 2045, 10, :o2, 19746263, 8
- tz.transition 2046, 4, :o3, 29621243, 12
- tz.transition 2046, 10, :o2, 19749175, 8
- tz.transition 2047, 4, :o3, 29625695, 12
- tz.transition 2047, 10, :o2, 19752087, 8
- tz.transition 2048, 4, :o3, 29630063, 12
- tz.transition 2048, 10, :o2, 19754999, 8
- tz.transition 2049, 4, :o3, 29634431, 12
- tz.transition 2049, 10, :o2, 19757967, 8
- tz.transition 2050, 4, :o3, 29638799, 12
- tz.transition 2050, 10, :o2, 19760879, 8
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Almaty.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Almaty.rb
deleted file mode 100644
index 9ee18970f1..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Almaty.rb
+++ /dev/null
@@ -1,67 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Almaty
- include TimezoneDefinition
-
- timezone 'Asia/Almaty' do |tz|
- tz.offset :o0, 18468, 0, :LMT
- tz.offset :o1, 18000, 0, :ALMT
- tz.offset :o2, 21600, 0, :ALMT
- tz.offset :o3, 21600, 3600, :ALMST
-
- tz.transition 1924, 5, :o1, 1939125829, 800
- tz.transition 1930, 6, :o2, 58227559, 24
- tz.transition 1981, 3, :o3, 354909600
- tz.transition 1981, 9, :o2, 370717200
- tz.transition 1982, 3, :o3, 386445600
- tz.transition 1982, 9, :o2, 402253200
- tz.transition 1983, 3, :o3, 417981600
- tz.transition 1983, 9, :o2, 433789200
- tz.transition 1984, 3, :o3, 449604000
- tz.transition 1984, 9, :o2, 465336000
- tz.transition 1985, 3, :o3, 481060800
- tz.transition 1985, 9, :o2, 496785600
- tz.transition 1986, 3, :o3, 512510400
- tz.transition 1986, 9, :o2, 528235200
- tz.transition 1987, 3, :o3, 543960000
- tz.transition 1987, 9, :o2, 559684800
- tz.transition 1988, 3, :o3, 575409600
- tz.transition 1988, 9, :o2, 591134400
- tz.transition 1989, 3, :o3, 606859200
- tz.transition 1989, 9, :o2, 622584000
- tz.transition 1990, 3, :o3, 638308800
- tz.transition 1990, 9, :o2, 654638400
- tz.transition 1992, 3, :o3, 701802000
- tz.transition 1992, 9, :o2, 717523200
- tz.transition 1993, 3, :o3, 733262400
- tz.transition 1993, 9, :o2, 748987200
- tz.transition 1994, 3, :o3, 764712000
- tz.transition 1994, 9, :o2, 780436800
- tz.transition 1995, 3, :o3, 796161600
- tz.transition 1995, 9, :o2, 811886400
- tz.transition 1996, 3, :o3, 828216000
- tz.transition 1996, 10, :o2, 846360000
- tz.transition 1997, 3, :o3, 859665600
- tz.transition 1997, 10, :o2, 877809600
- tz.transition 1998, 3, :o3, 891115200
- tz.transition 1998, 10, :o2, 909259200
- tz.transition 1999, 3, :o3, 922564800
- tz.transition 1999, 10, :o2, 941313600
- tz.transition 2000, 3, :o3, 954014400
- tz.transition 2000, 10, :o2, 972763200
- tz.transition 2001, 3, :o3, 985464000
- tz.transition 2001, 10, :o2, 1004212800
- tz.transition 2002, 3, :o3, 1017518400
- tz.transition 2002, 10, :o2, 1035662400
- tz.transition 2003, 3, :o3, 1048968000
- tz.transition 2003, 10, :o2, 1067112000
- tz.transition 2004, 3, :o3, 1080417600
- tz.transition 2004, 10, :o2, 1099166400
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Baghdad.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Baghdad.rb
deleted file mode 100644
index 774dca1587..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Baghdad.rb
+++ /dev/null
@@ -1,73 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Baghdad
- include TimezoneDefinition
-
- timezone 'Asia/Baghdad' do |tz|
- tz.offset :o0, 10660, 0, :LMT
- tz.offset :o1, 10656, 0, :BMT
- tz.offset :o2, 10800, 0, :AST
- tz.offset :o3, 10800, 3600, :ADT
-
- tz.transition 1889, 12, :o1, 10417111387, 4320
- tz.transition 1917, 12, :o2, 726478313, 300
- tz.transition 1982, 4, :o3, 389048400
- tz.transition 1982, 9, :o2, 402264000
- tz.transition 1983, 3, :o3, 417906000
- tz.transition 1983, 9, :o2, 433800000
- tz.transition 1984, 3, :o3, 449614800
- tz.transition 1984, 9, :o2, 465422400
- tz.transition 1985, 3, :o3, 481150800
- tz.transition 1985, 9, :o2, 496792800
- tz.transition 1986, 3, :o3, 512517600
- tz.transition 1986, 9, :o2, 528242400
- tz.transition 1987, 3, :o3, 543967200
- tz.transition 1987, 9, :o2, 559692000
- tz.transition 1988, 3, :o3, 575416800
- tz.transition 1988, 9, :o2, 591141600
- tz.transition 1989, 3, :o3, 606866400
- tz.transition 1989, 9, :o2, 622591200
- tz.transition 1990, 3, :o3, 638316000
- tz.transition 1990, 9, :o2, 654645600
- tz.transition 1991, 4, :o3, 670464000
- tz.transition 1991, 10, :o2, 686275200
- tz.transition 1992, 4, :o3, 702086400
- tz.transition 1992, 10, :o2, 717897600
- tz.transition 1993, 4, :o3, 733622400
- tz.transition 1993, 10, :o2, 749433600
- tz.transition 1994, 4, :o3, 765158400
- tz.transition 1994, 10, :o2, 780969600
- tz.transition 1995, 4, :o3, 796694400
- tz.transition 1995, 10, :o2, 812505600
- tz.transition 1996, 4, :o3, 828316800
- tz.transition 1996, 10, :o2, 844128000
- tz.transition 1997, 4, :o3, 859852800
- tz.transition 1997, 10, :o2, 875664000
- tz.transition 1998, 4, :o3, 891388800
- tz.transition 1998, 10, :o2, 907200000
- tz.transition 1999, 4, :o3, 922924800
- tz.transition 1999, 10, :o2, 938736000
- tz.transition 2000, 4, :o3, 954547200
- tz.transition 2000, 10, :o2, 970358400
- tz.transition 2001, 4, :o3, 986083200
- tz.transition 2001, 10, :o2, 1001894400
- tz.transition 2002, 4, :o3, 1017619200
- tz.transition 2002, 10, :o2, 1033430400
- tz.transition 2003, 4, :o3, 1049155200
- tz.transition 2003, 10, :o2, 1064966400
- tz.transition 2004, 4, :o3, 1080777600
- tz.transition 2004, 10, :o2, 1096588800
- tz.transition 2005, 4, :o3, 1112313600
- tz.transition 2005, 10, :o2, 1128124800
- tz.transition 2006, 4, :o3, 1143849600
- tz.transition 2006, 10, :o2, 1159660800
- tz.transition 2007, 4, :o3, 1175385600
- tz.transition 2007, 10, :o2, 1191196800
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Baku.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Baku.rb
deleted file mode 100644
index e86340ebfa..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Baku.rb
+++ /dev/null
@@ -1,161 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Baku
- include TimezoneDefinition
-
- timezone 'Asia/Baku' do |tz|
- tz.offset :o0, 11964, 0, :LMT
- tz.offset :o1, 10800, 0, :BAKT
- tz.offset :o2, 14400, 0, :BAKT
- tz.offset :o3, 14400, 3600, :BAKST
- tz.offset :o4, 10800, 3600, :BAKST
- tz.offset :o5, 10800, 3600, :AZST
- tz.offset :o6, 10800, 0, :AZT
- tz.offset :o7, 14400, 0, :AZT
- tz.offset :o8, 14400, 3600, :AZST
-
- tz.transition 1924, 5, :o1, 17452133003, 7200
- tz.transition 1957, 2, :o2, 19487187, 8
- tz.transition 1981, 3, :o3, 354916800
- tz.transition 1981, 9, :o2, 370724400
- tz.transition 1982, 3, :o3, 386452800
- tz.transition 1982, 9, :o2, 402260400
- tz.transition 1983, 3, :o3, 417988800
- tz.transition 1983, 9, :o2, 433796400
- tz.transition 1984, 3, :o3, 449611200
- tz.transition 1984, 9, :o2, 465343200
- tz.transition 1985, 3, :o3, 481068000
- tz.transition 1985, 9, :o2, 496792800
- tz.transition 1986, 3, :o3, 512517600
- tz.transition 1986, 9, :o2, 528242400
- tz.transition 1987, 3, :o3, 543967200
- tz.transition 1987, 9, :o2, 559692000
- tz.transition 1988, 3, :o3, 575416800
- tz.transition 1988, 9, :o2, 591141600
- tz.transition 1989, 3, :o3, 606866400
- tz.transition 1989, 9, :o2, 622591200
- tz.transition 1990, 3, :o3, 638316000
- tz.transition 1990, 9, :o2, 654645600
- tz.transition 1991, 3, :o4, 670370400
- tz.transition 1991, 8, :o5, 683496000
- tz.transition 1991, 9, :o6, 686098800
- tz.transition 1992, 3, :o5, 701812800
- tz.transition 1992, 9, :o7, 717534000
- tz.transition 1996, 3, :o8, 828234000
- tz.transition 1996, 10, :o7, 846378000
- tz.transition 1997, 3, :o8, 859680000
- tz.transition 1997, 10, :o7, 877824000
- tz.transition 1998, 3, :o8, 891129600
- tz.transition 1998, 10, :o7, 909273600
- tz.transition 1999, 3, :o8, 922579200
- tz.transition 1999, 10, :o7, 941328000
- tz.transition 2000, 3, :o8, 954028800
- tz.transition 2000, 10, :o7, 972777600
- tz.transition 2001, 3, :o8, 985478400
- tz.transition 2001, 10, :o7, 1004227200
- tz.transition 2002, 3, :o8, 1017532800
- tz.transition 2002, 10, :o7, 1035676800
- tz.transition 2003, 3, :o8, 1048982400
- tz.transition 2003, 10, :o7, 1067126400
- tz.transition 2004, 3, :o8, 1080432000
- tz.transition 2004, 10, :o7, 1099180800
- tz.transition 2005, 3, :o8, 1111881600
- tz.transition 2005, 10, :o7, 1130630400
- tz.transition 2006, 3, :o8, 1143331200
- tz.transition 2006, 10, :o7, 1162080000
- tz.transition 2007, 3, :o8, 1174780800
- tz.transition 2007, 10, :o7, 1193529600
- tz.transition 2008, 3, :o8, 1206835200
- tz.transition 2008, 10, :o7, 1224979200
- tz.transition 2009, 3, :o8, 1238284800
- tz.transition 2009, 10, :o7, 1256428800
- tz.transition 2010, 3, :o8, 1269734400
- tz.transition 2010, 10, :o7, 1288483200
- tz.transition 2011, 3, :o8, 1301184000
- tz.transition 2011, 10, :o7, 1319932800
- tz.transition 2012, 3, :o8, 1332633600
- tz.transition 2012, 10, :o7, 1351382400
- tz.transition 2013, 3, :o8, 1364688000
- tz.transition 2013, 10, :o7, 1382832000
- tz.transition 2014, 3, :o8, 1396137600
- tz.transition 2014, 10, :o7, 1414281600
- tz.transition 2015, 3, :o8, 1427587200
- tz.transition 2015, 10, :o7, 1445731200
- tz.transition 2016, 3, :o8, 1459036800
- tz.transition 2016, 10, :o7, 1477785600
- tz.transition 2017, 3, :o8, 1490486400
- tz.transition 2017, 10, :o7, 1509235200
- tz.transition 2018, 3, :o8, 1521936000
- tz.transition 2018, 10, :o7, 1540684800
- tz.transition 2019, 3, :o8, 1553990400
- tz.transition 2019, 10, :o7, 1572134400
- tz.transition 2020, 3, :o8, 1585440000
- tz.transition 2020, 10, :o7, 1603584000
- tz.transition 2021, 3, :o8, 1616889600
- tz.transition 2021, 10, :o7, 1635638400
- tz.transition 2022, 3, :o8, 1648339200
- tz.transition 2022, 10, :o7, 1667088000
- tz.transition 2023, 3, :o8, 1679788800
- tz.transition 2023, 10, :o7, 1698537600
- tz.transition 2024, 3, :o8, 1711843200
- tz.transition 2024, 10, :o7, 1729987200
- tz.transition 2025, 3, :o8, 1743292800
- tz.transition 2025, 10, :o7, 1761436800
- tz.transition 2026, 3, :o8, 1774742400
- tz.transition 2026, 10, :o7, 1792886400
- tz.transition 2027, 3, :o8, 1806192000
- tz.transition 2027, 10, :o7, 1824940800
- tz.transition 2028, 3, :o8, 1837641600
- tz.transition 2028, 10, :o7, 1856390400
- tz.transition 2029, 3, :o8, 1869091200
- tz.transition 2029, 10, :o7, 1887840000
- tz.transition 2030, 3, :o8, 1901145600
- tz.transition 2030, 10, :o7, 1919289600
- tz.transition 2031, 3, :o8, 1932595200
- tz.transition 2031, 10, :o7, 1950739200
- tz.transition 2032, 3, :o8, 1964044800
- tz.transition 2032, 10, :o7, 1982793600
- tz.transition 2033, 3, :o8, 1995494400
- tz.transition 2033, 10, :o7, 2014243200
- tz.transition 2034, 3, :o8, 2026944000
- tz.transition 2034, 10, :o7, 2045692800
- tz.transition 2035, 3, :o8, 2058393600
- tz.transition 2035, 10, :o7, 2077142400
- tz.transition 2036, 3, :o8, 2090448000
- tz.transition 2036, 10, :o7, 2108592000
- tz.transition 2037, 3, :o8, 2121897600
- tz.transition 2037, 10, :o7, 2140041600
- tz.transition 2038, 3, :o8, 4931021, 2
- tz.transition 2038, 10, :o7, 4931455, 2
- tz.transition 2039, 3, :o8, 4931749, 2
- tz.transition 2039, 10, :o7, 4932183, 2
- tz.transition 2040, 3, :o8, 4932477, 2
- tz.transition 2040, 10, :o7, 4932911, 2
- tz.transition 2041, 3, :o8, 4933219, 2
- tz.transition 2041, 10, :o7, 4933639, 2
- tz.transition 2042, 3, :o8, 4933947, 2
- tz.transition 2042, 10, :o7, 4934367, 2
- tz.transition 2043, 3, :o8, 4934675, 2
- tz.transition 2043, 10, :o7, 4935095, 2
- tz.transition 2044, 3, :o8, 4935403, 2
- tz.transition 2044, 10, :o7, 4935837, 2
- tz.transition 2045, 3, :o8, 4936131, 2
- tz.transition 2045, 10, :o7, 4936565, 2
- tz.transition 2046, 3, :o8, 4936859, 2
- tz.transition 2046, 10, :o7, 4937293, 2
- tz.transition 2047, 3, :o8, 4937601, 2
- tz.transition 2047, 10, :o7, 4938021, 2
- tz.transition 2048, 3, :o8, 4938329, 2
- tz.transition 2048, 10, :o7, 4938749, 2
- tz.transition 2049, 3, :o8, 4939057, 2
- tz.transition 2049, 10, :o7, 4939491, 2
- tz.transition 2050, 3, :o8, 4939785, 2
- tz.transition 2050, 10, :o7, 4940219, 2
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Bangkok.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Bangkok.rb
deleted file mode 100644
index 139194e5e5..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Bangkok.rb
+++ /dev/null
@@ -1,20 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Bangkok
- include TimezoneDefinition
-
- timezone 'Asia/Bangkok' do |tz|
- tz.offset :o0, 24124, 0, :LMT
- tz.offset :o1, 24124, 0, :BMT
- tz.offset :o2, 25200, 0, :ICT
-
- tz.transition 1879, 12, :o1, 52006648769, 21600
- tz.transition 1920, 3, :o2, 52324168769, 21600
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Chongqing.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Chongqing.rb
deleted file mode 100644
index 8c94b4ba86..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Chongqing.rb
+++ /dev/null
@@ -1,33 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Chongqing
- include TimezoneDefinition
-
- timezone 'Asia/Chongqing' do |tz|
- tz.offset :o0, 25580, 0, :LMT
- tz.offset :o1, 25200, 0, :LONT
- tz.offset :o2, 28800, 0, :CST
- tz.offset :o3, 28800, 3600, :CDT
-
- tz.transition 1927, 12, :o1, 10477063601, 4320
- tz.transition 1980, 4, :o2, 325962000
- tz.transition 1986, 5, :o3, 515520000
- tz.transition 1986, 9, :o2, 527007600
- tz.transition 1987, 4, :o3, 545155200
- tz.transition 1987, 9, :o2, 558457200
- tz.transition 1988, 4, :o3, 576604800
- tz.transition 1988, 9, :o2, 589906800
- tz.transition 1989, 4, :o3, 608659200
- tz.transition 1989, 9, :o2, 621961200
- tz.transition 1990, 4, :o3, 640108800
- tz.transition 1990, 9, :o2, 653410800
- tz.transition 1991, 4, :o3, 671558400
- tz.transition 1991, 9, :o2, 684860400
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Colombo.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Colombo.rb
deleted file mode 100644
index f6531fa819..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Colombo.rb
+++ /dev/null
@@ -1,30 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Colombo
- include TimezoneDefinition
-
- timezone 'Asia/Colombo' do |tz|
- tz.offset :o0, 19164, 0, :LMT
- tz.offset :o1, 19172, 0, :MMT
- tz.offset :o2, 19800, 0, :IST
- tz.offset :o3, 19800, 1800, :IHST
- tz.offset :o4, 19800, 3600, :IST
- tz.offset :o5, 23400, 0, :LKT
- tz.offset :o6, 21600, 0, :LKT
-
- tz.transition 1879, 12, :o1, 17335550003, 7200
- tz.transition 1905, 12, :o2, 52211763607, 21600
- tz.transition 1942, 1, :o3, 116657485, 48
- tz.transition 1942, 8, :o4, 9722413, 4
- tz.transition 1945, 10, :o2, 38907909, 16
- tz.transition 1996, 5, :o5, 832962600
- tz.transition 1996, 10, :o6, 846266400
- tz.transition 2006, 4, :o2, 1145039400
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Dhaka.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Dhaka.rb
deleted file mode 100644
index 46dce9a0d0..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Dhaka.rb
+++ /dev/null
@@ -1,29 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Dhaka
- include TimezoneDefinition
-
- timezone 'Asia/Dhaka' do |tz|
- tz.offset :o0, 21700, 0, :LMT
- tz.offset :o1, 21200, 0, :HMT
- tz.offset :o2, 23400, 0, :BURT
- tz.offset :o3, 19800, 0, :IST
- tz.offset :o4, 21600, 0, :DACT
- tz.offset :o5, 21600, 0, :BDT
- tz.offset :o6, 21600, 3600, :BDST
-
- tz.transition 1889, 12, :o1, 2083422167, 864
- tz.transition 1941, 9, :o2, 524937943, 216
- tz.transition 1942, 5, :o3, 116663723, 48
- tz.transition 1942, 8, :o2, 116668957, 48
- tz.transition 1951, 9, :o4, 116828123, 48
- tz.transition 1971, 3, :o5, 38772000
- tz.transition 2009, 6, :o6, 1245430800
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Hong_Kong.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Hong_Kong.rb
deleted file mode 100644
index f1edd75ac8..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Hong_Kong.rb
+++ /dev/null
@@ -1,87 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Hong_Kong
- include TimezoneDefinition
-
- timezone 'Asia/Hong_Kong' do |tz|
- tz.offset :o0, 27396, 0, :LMT
- tz.offset :o1, 28800, 0, :HKT
- tz.offset :o2, 28800, 3600, :HKST
-
- tz.transition 1904, 10, :o1, 5800279639, 2400
- tz.transition 1946, 4, :o2, 38910885, 16
- tz.transition 1946, 11, :o1, 116743453, 48
- tz.transition 1947, 4, :o2, 38916613, 16
- tz.transition 1947, 12, :o1, 116762365, 48
- tz.transition 1948, 5, :o2, 38922773, 16
- tz.transition 1948, 10, :o1, 116777053, 48
- tz.transition 1949, 4, :o2, 38928149, 16
- tz.transition 1949, 10, :o1, 116794525, 48
- tz.transition 1950, 4, :o2, 38933973, 16
- tz.transition 1950, 10, :o1, 116811997, 48
- tz.transition 1951, 3, :o2, 38939797, 16
- tz.transition 1951, 10, :o1, 116829469, 48
- tz.transition 1952, 4, :o2, 38945733, 16
- tz.transition 1952, 10, :o1, 116846941, 48
- tz.transition 1953, 4, :o2, 38951557, 16
- tz.transition 1953, 10, :o1, 116864749, 48
- tz.transition 1954, 3, :o2, 38957157, 16
- tz.transition 1954, 10, :o1, 116882221, 48
- tz.transition 1955, 3, :o2, 38962981, 16
- tz.transition 1955, 11, :o1, 116900029, 48
- tz.transition 1956, 3, :o2, 38968805, 16
- tz.transition 1956, 11, :o1, 116917501, 48
- tz.transition 1957, 3, :o2, 38974741, 16
- tz.transition 1957, 11, :o1, 116934973, 48
- tz.transition 1958, 3, :o2, 38980565, 16
- tz.transition 1958, 11, :o1, 116952445, 48
- tz.transition 1959, 3, :o2, 38986389, 16
- tz.transition 1959, 10, :o1, 116969917, 48
- tz.transition 1960, 3, :o2, 38992213, 16
- tz.transition 1960, 11, :o1, 116987725, 48
- tz.transition 1961, 3, :o2, 38998037, 16
- tz.transition 1961, 11, :o1, 117005197, 48
- tz.transition 1962, 3, :o2, 39003861, 16
- tz.transition 1962, 11, :o1, 117022669, 48
- tz.transition 1963, 3, :o2, 39009797, 16
- tz.transition 1963, 11, :o1, 117040141, 48
- tz.transition 1964, 3, :o2, 39015621, 16
- tz.transition 1964, 10, :o1, 117057613, 48
- tz.transition 1965, 4, :o2, 39021893, 16
- tz.transition 1965, 10, :o1, 117074413, 48
- tz.transition 1966, 4, :o2, 39027717, 16
- tz.transition 1966, 10, :o1, 117091885, 48
- tz.transition 1967, 4, :o2, 39033541, 16
- tz.transition 1967, 10, :o1, 117109693, 48
- tz.transition 1968, 4, :o2, 39039477, 16
- tz.transition 1968, 10, :o1, 117127165, 48
- tz.transition 1969, 4, :o2, 39045301, 16
- tz.transition 1969, 10, :o1, 117144637, 48
- tz.transition 1970, 4, :o2, 9315000
- tz.transition 1970, 10, :o1, 25036200
- tz.transition 1971, 4, :o2, 40764600
- tz.transition 1971, 10, :o1, 56485800
- tz.transition 1972, 4, :o2, 72214200
- tz.transition 1972, 10, :o1, 88540200
- tz.transition 1973, 4, :o2, 104268600
- tz.transition 1973, 10, :o1, 119989800
- tz.transition 1974, 4, :o2, 135718200
- tz.transition 1974, 10, :o1, 151439400
- tz.transition 1975, 4, :o2, 167167800
- tz.transition 1975, 10, :o1, 182889000
- tz.transition 1976, 4, :o2, 198617400
- tz.transition 1976, 10, :o1, 214338600
- tz.transition 1977, 4, :o2, 230067000
- tz.transition 1977, 10, :o1, 245788200
- tz.transition 1979, 5, :o2, 295385400
- tz.transition 1979, 10, :o1, 309292200
- tz.transition 1980, 5, :o2, 326835000
- tz.transition 1980, 10, :o1, 340741800
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Irkutsk.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Irkutsk.rb
deleted file mode 100644
index 2d47d9580b..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Irkutsk.rb
+++ /dev/null
@@ -1,165 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Irkutsk
- include TimezoneDefinition
-
- timezone 'Asia/Irkutsk' do |tz|
- tz.offset :o0, 25040, 0, :LMT
- tz.offset :o1, 25040, 0, :IMT
- tz.offset :o2, 25200, 0, :IRKT
- tz.offset :o3, 28800, 0, :IRKT
- tz.offset :o4, 28800, 3600, :IRKST
- tz.offset :o5, 25200, 3600, :IRKST
-
- tz.transition 1879, 12, :o1, 2600332427, 1080
- tz.transition 1920, 1, :o2, 2616136067, 1080
- tz.transition 1930, 6, :o3, 58227557, 24
- tz.transition 1981, 3, :o4, 354902400
- tz.transition 1981, 9, :o3, 370710000
- tz.transition 1982, 3, :o4, 386438400
- tz.transition 1982, 9, :o3, 402246000
- tz.transition 1983, 3, :o4, 417974400
- tz.transition 1983, 9, :o3, 433782000
- tz.transition 1984, 3, :o4, 449596800
- tz.transition 1984, 9, :o3, 465328800
- tz.transition 1985, 3, :o4, 481053600
- tz.transition 1985, 9, :o3, 496778400
- tz.transition 1986, 3, :o4, 512503200
- tz.transition 1986, 9, :o3, 528228000
- tz.transition 1987, 3, :o4, 543952800
- tz.transition 1987, 9, :o3, 559677600
- tz.transition 1988, 3, :o4, 575402400
- tz.transition 1988, 9, :o3, 591127200
- tz.transition 1989, 3, :o4, 606852000
- tz.transition 1989, 9, :o3, 622576800
- tz.transition 1990, 3, :o4, 638301600
- tz.transition 1990, 9, :o3, 654631200
- tz.transition 1991, 3, :o5, 670356000
- tz.transition 1991, 9, :o2, 686084400
- tz.transition 1992, 1, :o3, 695761200
- tz.transition 1992, 3, :o4, 701794800
- tz.transition 1992, 9, :o3, 717516000
- tz.transition 1993, 3, :o4, 733255200
- tz.transition 1993, 9, :o3, 748980000
- tz.transition 1994, 3, :o4, 764704800
- tz.transition 1994, 9, :o3, 780429600
- tz.transition 1995, 3, :o4, 796154400
- tz.transition 1995, 9, :o3, 811879200
- tz.transition 1996, 3, :o4, 828208800
- tz.transition 1996, 10, :o3, 846352800
- tz.transition 1997, 3, :o4, 859658400
- tz.transition 1997, 10, :o3, 877802400
- tz.transition 1998, 3, :o4, 891108000
- tz.transition 1998, 10, :o3, 909252000
- tz.transition 1999, 3, :o4, 922557600
- tz.transition 1999, 10, :o3, 941306400
- tz.transition 2000, 3, :o4, 954007200
- tz.transition 2000, 10, :o3, 972756000
- tz.transition 2001, 3, :o4, 985456800
- tz.transition 2001, 10, :o3, 1004205600
- tz.transition 2002, 3, :o4, 1017511200
- tz.transition 2002, 10, :o3, 1035655200
- tz.transition 2003, 3, :o4, 1048960800
- tz.transition 2003, 10, :o3, 1067104800
- tz.transition 2004, 3, :o4, 1080410400
- tz.transition 2004, 10, :o3, 1099159200
- tz.transition 2005, 3, :o4, 1111860000
- tz.transition 2005, 10, :o3, 1130608800
- tz.transition 2006, 3, :o4, 1143309600
- tz.transition 2006, 10, :o3, 1162058400
- tz.transition 2007, 3, :o4, 1174759200
- tz.transition 2007, 10, :o3, 1193508000
- tz.transition 2008, 3, :o4, 1206813600
- tz.transition 2008, 10, :o3, 1224957600
- tz.transition 2009, 3, :o4, 1238263200
- tz.transition 2009, 10, :o3, 1256407200
- tz.transition 2010, 3, :o4, 1269712800
- tz.transition 2010, 10, :o3, 1288461600
- tz.transition 2011, 3, :o4, 1301162400
- tz.transition 2011, 10, :o3, 1319911200
- tz.transition 2012, 3, :o4, 1332612000
- tz.transition 2012, 10, :o3, 1351360800
- tz.transition 2013, 3, :o4, 1364666400
- tz.transition 2013, 10, :o3, 1382810400
- tz.transition 2014, 3, :o4, 1396116000
- tz.transition 2014, 10, :o3, 1414260000
- tz.transition 2015, 3, :o4, 1427565600
- tz.transition 2015, 10, :o3, 1445709600
- tz.transition 2016, 3, :o4, 1459015200
- tz.transition 2016, 10, :o3, 1477764000
- tz.transition 2017, 3, :o4, 1490464800
- tz.transition 2017, 10, :o3, 1509213600
- tz.transition 2018, 3, :o4, 1521914400
- tz.transition 2018, 10, :o3, 1540663200
- tz.transition 2019, 3, :o4, 1553968800
- tz.transition 2019, 10, :o3, 1572112800
- tz.transition 2020, 3, :o4, 1585418400
- tz.transition 2020, 10, :o3, 1603562400
- tz.transition 2021, 3, :o4, 1616868000
- tz.transition 2021, 10, :o3, 1635616800
- tz.transition 2022, 3, :o4, 1648317600
- tz.transition 2022, 10, :o3, 1667066400
- tz.transition 2023, 3, :o4, 1679767200
- tz.transition 2023, 10, :o3, 1698516000
- tz.transition 2024, 3, :o4, 1711821600
- tz.transition 2024, 10, :o3, 1729965600
- tz.transition 2025, 3, :o4, 1743271200
- tz.transition 2025, 10, :o3, 1761415200
- tz.transition 2026, 3, :o4, 1774720800
- tz.transition 2026, 10, :o3, 1792864800
- tz.transition 2027, 3, :o4, 1806170400
- tz.transition 2027, 10, :o3, 1824919200
- tz.transition 2028, 3, :o4, 1837620000
- tz.transition 2028, 10, :o3, 1856368800
- tz.transition 2029, 3, :o4, 1869069600
- tz.transition 2029, 10, :o3, 1887818400
- tz.transition 2030, 3, :o4, 1901124000
- tz.transition 2030, 10, :o3, 1919268000
- tz.transition 2031, 3, :o4, 1932573600
- tz.transition 2031, 10, :o3, 1950717600
- tz.transition 2032, 3, :o4, 1964023200
- tz.transition 2032, 10, :o3, 1982772000
- tz.transition 2033, 3, :o4, 1995472800
- tz.transition 2033, 10, :o3, 2014221600
- tz.transition 2034, 3, :o4, 2026922400
- tz.transition 2034, 10, :o3, 2045671200
- tz.transition 2035, 3, :o4, 2058372000
- tz.transition 2035, 10, :o3, 2077120800
- tz.transition 2036, 3, :o4, 2090426400
- tz.transition 2036, 10, :o3, 2108570400
- tz.transition 2037, 3, :o4, 2121876000
- tz.transition 2037, 10, :o3, 2140020000
- tz.transition 2038, 3, :o4, 9862041, 4
- tz.transition 2038, 10, :o3, 9862909, 4
- tz.transition 2039, 3, :o4, 9863497, 4
- tz.transition 2039, 10, :o3, 9864365, 4
- tz.transition 2040, 3, :o4, 9864953, 4
- tz.transition 2040, 10, :o3, 9865821, 4
- tz.transition 2041, 3, :o4, 9866437, 4
- tz.transition 2041, 10, :o3, 9867277, 4
- tz.transition 2042, 3, :o4, 9867893, 4
- tz.transition 2042, 10, :o3, 9868733, 4
- tz.transition 2043, 3, :o4, 9869349, 4
- tz.transition 2043, 10, :o3, 9870189, 4
- tz.transition 2044, 3, :o4, 9870805, 4
- tz.transition 2044, 10, :o3, 9871673, 4
- tz.transition 2045, 3, :o4, 9872261, 4
- tz.transition 2045, 10, :o3, 9873129, 4
- tz.transition 2046, 3, :o4, 9873717, 4
- tz.transition 2046, 10, :o3, 9874585, 4
- tz.transition 2047, 3, :o4, 9875201, 4
- tz.transition 2047, 10, :o3, 9876041, 4
- tz.transition 2048, 3, :o4, 9876657, 4
- tz.transition 2048, 10, :o3, 9877497, 4
- tz.transition 2049, 3, :o4, 9878113, 4
- tz.transition 2049, 10, :o3, 9878981, 4
- tz.transition 2050, 3, :o4, 9879569, 4
- tz.transition 2050, 10, :o3, 9880437, 4
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Jakarta.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Jakarta.rb
deleted file mode 100644
index cc58fa173b..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Jakarta.rb
+++ /dev/null
@@ -1,30 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Jakarta
- include TimezoneDefinition
-
- timezone 'Asia/Jakarta' do |tz|
- tz.offset :o0, 25632, 0, :LMT
- tz.offset :o1, 25632, 0, :JMT
- tz.offset :o2, 26400, 0, :JAVT
- tz.offset :o3, 27000, 0, :WIT
- tz.offset :o4, 32400, 0, :JST
- tz.offset :o5, 28800, 0, :WIT
- tz.offset :o6, 25200, 0, :WIT
-
- tz.transition 1867, 8, :o1, 720956461, 300
- tz.transition 1923, 12, :o2, 87256267, 36
- tz.transition 1932, 10, :o3, 87372439, 36
- tz.transition 1942, 3, :o4, 38887059, 16
- tz.transition 1945, 9, :o3, 19453769, 8
- tz.transition 1948, 4, :o5, 38922755, 16
- tz.transition 1950, 4, :o3, 14600413, 6
- tz.transition 1963, 12, :o6, 39014323, 16
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Jerusalem.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Jerusalem.rb
deleted file mode 100644
index 9b737b899e..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Jerusalem.rb
+++ /dev/null
@@ -1,163 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Jerusalem
- include TimezoneDefinition
-
- timezone 'Asia/Jerusalem' do |tz|
- tz.offset :o0, 8456, 0, :LMT
- tz.offset :o1, 8440, 0, :JMT
- tz.offset :o2, 7200, 0, :IST
- tz.offset :o3, 7200, 3600, :IDT
- tz.offset :o4, 7200, 7200, :IDDT
-
- tz.transition 1879, 12, :o1, 26003326343, 10800
- tz.transition 1917, 12, :o2, 5230643909, 2160
- tz.transition 1940, 5, :o3, 29157377, 12
- tz.transition 1942, 10, :o2, 19445315, 8
- tz.transition 1943, 4, :o3, 4861631, 2
- tz.transition 1943, 10, :o2, 19448235, 8
- tz.transition 1944, 3, :o3, 29174177, 12
- tz.transition 1944, 10, :o2, 19451163, 8
- tz.transition 1945, 4, :o3, 29178737, 12
- tz.transition 1945, 10, :o2, 58362251, 24
- tz.transition 1946, 4, :o3, 4863853, 2
- tz.transition 1946, 10, :o2, 19457003, 8
- tz.transition 1948, 5, :o4, 29192333, 12
- tz.transition 1948, 8, :o3, 7298386, 3
- tz.transition 1948, 10, :o2, 58388555, 24
- tz.transition 1949, 4, :o3, 29196449, 12
- tz.transition 1949, 10, :o2, 58397315, 24
- tz.transition 1950, 4, :o3, 29200649, 12
- tz.transition 1950, 9, :o2, 4867079, 2
- tz.transition 1951, 3, :o3, 29204849, 12
- tz.transition 1951, 11, :o2, 4867923, 2
- tz.transition 1952, 4, :o3, 4868245, 2
- tz.transition 1952, 10, :o2, 4868609, 2
- tz.transition 1953, 4, :o3, 4868959, 2
- tz.transition 1953, 9, :o2, 4869267, 2
- tz.transition 1954, 6, :o3, 29218877, 12
- tz.transition 1954, 9, :o2, 19479979, 8
- tz.transition 1955, 6, :o3, 4870539, 2
- tz.transition 1955, 9, :o2, 19482891, 8
- tz.transition 1956, 6, :o3, 29227529, 12
- tz.transition 1956, 9, :o2, 4871493, 2
- tz.transition 1957, 4, :o3, 4871915, 2
- tz.transition 1957, 9, :o2, 19488827, 8
- tz.transition 1974, 7, :o3, 142380000
- tz.transition 1974, 10, :o2, 150843600
- tz.transition 1975, 4, :o3, 167176800
- tz.transition 1975, 8, :o2, 178664400
- tz.transition 1985, 4, :o3, 482277600
- tz.transition 1985, 9, :o2, 495579600
- tz.transition 1986, 5, :o3, 516751200
- tz.transition 1986, 9, :o2, 526424400
- tz.transition 1987, 4, :o3, 545436000
- tz.transition 1987, 9, :o2, 558478800
- tz.transition 1988, 4, :o3, 576540000
- tz.transition 1988, 9, :o2, 589237200
- tz.transition 1989, 4, :o3, 609890400
- tz.transition 1989, 9, :o2, 620773200
- tz.transition 1990, 3, :o3, 638316000
- tz.transition 1990, 8, :o2, 651618000
- tz.transition 1991, 3, :o3, 669765600
- tz.transition 1991, 8, :o2, 683672400
- tz.transition 1992, 3, :o3, 701820000
- tz.transition 1992, 9, :o2, 715726800
- tz.transition 1993, 4, :o3, 733701600
- tz.transition 1993, 9, :o2, 747176400
- tz.transition 1994, 3, :o3, 765151200
- tz.transition 1994, 8, :o2, 778021200
- tz.transition 1995, 3, :o3, 796600800
- tz.transition 1995, 9, :o2, 810075600
- tz.transition 1996, 3, :o3, 826840800
- tz.transition 1996, 9, :o2, 842821200
- tz.transition 1997, 3, :o3, 858895200
- tz.transition 1997, 9, :o2, 874184400
- tz.transition 1998, 3, :o3, 890344800
- tz.transition 1998, 9, :o2, 905029200
- tz.transition 1999, 4, :o3, 923011200
- tz.transition 1999, 9, :o2, 936313200
- tz.transition 2000, 4, :o3, 955670400
- tz.transition 2000, 10, :o2, 970783200
- tz.transition 2001, 4, :o3, 986770800
- tz.transition 2001, 9, :o2, 1001282400
- tz.transition 2002, 3, :o3, 1017356400
- tz.transition 2002, 10, :o2, 1033941600
- tz.transition 2003, 3, :o3, 1048806000
- tz.transition 2003, 10, :o2, 1065132000
- tz.transition 2004, 4, :o3, 1081292400
- tz.transition 2004, 9, :o2, 1095804000
- tz.transition 2005, 4, :o3, 1112313600
- tz.transition 2005, 10, :o2, 1128812400
- tz.transition 2006, 3, :o3, 1143763200
- tz.transition 2006, 9, :o2, 1159657200
- tz.transition 2007, 3, :o3, 1175212800
- tz.transition 2007, 9, :o2, 1189897200
- tz.transition 2008, 3, :o3, 1206662400
- tz.transition 2008, 10, :o2, 1223161200
- tz.transition 2009, 3, :o3, 1238112000
- tz.transition 2009, 9, :o2, 1254006000
- tz.transition 2010, 3, :o3, 1269561600
- tz.transition 2010, 9, :o2, 1284246000
- tz.transition 2011, 4, :o3, 1301616000
- tz.transition 2011, 10, :o2, 1317510000
- tz.transition 2012, 3, :o3, 1333065600
- tz.transition 2012, 9, :o2, 1348354800
- tz.transition 2013, 3, :o3, 1364515200
- tz.transition 2013, 9, :o2, 1378594800
- tz.transition 2014, 3, :o3, 1395964800
- tz.transition 2014, 9, :o2, 1411858800
- tz.transition 2015, 3, :o3, 1427414400
- tz.transition 2015, 9, :o2, 1442703600
- tz.transition 2016, 4, :o3, 1459468800
- tz.transition 2016, 10, :o2, 1475967600
- tz.transition 2017, 3, :o3, 1490918400
- tz.transition 2017, 9, :o2, 1506207600
- tz.transition 2018, 3, :o3, 1522368000
- tz.transition 2018, 9, :o2, 1537052400
- tz.transition 2019, 3, :o3, 1553817600
- tz.transition 2019, 10, :o2, 1570316400
- tz.transition 2020, 3, :o3, 1585267200
- tz.transition 2020, 9, :o2, 1601161200
- tz.transition 2021, 3, :o3, 1616716800
- tz.transition 2021, 9, :o2, 1631401200
- tz.transition 2022, 4, :o3, 1648771200
- tz.transition 2022, 10, :o2, 1664665200
- tz.transition 2023, 3, :o3, 1680220800
- tz.transition 2023, 9, :o2, 1695510000
- tz.transition 2024, 3, :o3, 1711670400
- tz.transition 2024, 10, :o2, 1728169200
- tz.transition 2025, 3, :o3, 1743120000
- tz.transition 2025, 9, :o2, 1759014000
- tz.transition 2026, 3, :o3, 1774569600
- tz.transition 2026, 9, :o2, 1789858800
- tz.transition 2027, 3, :o3, 1806019200
- tz.transition 2027, 10, :o2, 1823122800
- tz.transition 2028, 3, :o3, 1838073600
- tz.transition 2028, 9, :o2, 1853362800
- tz.transition 2029, 3, :o3, 1869523200
- tz.transition 2029, 9, :o2, 1884207600
- tz.transition 2030, 3, :o3, 1900972800
- tz.transition 2030, 10, :o2, 1917471600
- tz.transition 2031, 3, :o3, 1932422400
- tz.transition 2031, 9, :o2, 1947711600
- tz.transition 2032, 3, :o3, 1963872000
- tz.transition 2032, 9, :o2, 1978556400
- tz.transition 2033, 4, :o3, 1995926400
- tz.transition 2033, 10, :o2, 2011820400
- tz.transition 2034, 3, :o3, 2027376000
- tz.transition 2034, 9, :o2, 2042060400
- tz.transition 2035, 3, :o3, 2058825600
- tz.transition 2035, 10, :o2, 2075324400
- tz.transition 2036, 3, :o3, 2090275200
- tz.transition 2036, 9, :o2, 2106169200
- tz.transition 2037, 3, :o3, 2121724800
- tz.transition 2037, 9, :o2, 2136409200
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kabul.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kabul.rb
deleted file mode 100644
index 669c09790a..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kabul.rb
+++ /dev/null
@@ -1,20 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Kabul
- include TimezoneDefinition
-
- timezone 'Asia/Kabul' do |tz|
- tz.offset :o0, 16608, 0, :LMT
- tz.offset :o1, 14400, 0, :AFT
- tz.offset :o2, 16200, 0, :AFT
-
- tz.transition 1889, 12, :o1, 2170231477, 900
- tz.transition 1944, 12, :o2, 7294369, 3
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kamchatka.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kamchatka.rb
deleted file mode 100644
index 2f1690b3a9..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kamchatka.rb
+++ /dev/null
@@ -1,163 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Kamchatka
- include TimezoneDefinition
-
- timezone 'Asia/Kamchatka' do |tz|
- tz.offset :o0, 38076, 0, :LMT
- tz.offset :o1, 39600, 0, :PETT
- tz.offset :o2, 43200, 0, :PETT
- tz.offset :o3, 43200, 3600, :PETST
- tz.offset :o4, 39600, 3600, :PETST
-
- tz.transition 1922, 11, :o1, 17448250027, 7200
- tz.transition 1930, 6, :o2, 58227553, 24
- tz.transition 1981, 3, :o3, 354888000
- tz.transition 1981, 9, :o2, 370695600
- tz.transition 1982, 3, :o3, 386424000
- tz.transition 1982, 9, :o2, 402231600
- tz.transition 1983, 3, :o3, 417960000
- tz.transition 1983, 9, :o2, 433767600
- tz.transition 1984, 3, :o3, 449582400
- tz.transition 1984, 9, :o2, 465314400
- tz.transition 1985, 3, :o3, 481039200
- tz.transition 1985, 9, :o2, 496764000
- tz.transition 1986, 3, :o3, 512488800
- tz.transition 1986, 9, :o2, 528213600
- tz.transition 1987, 3, :o3, 543938400
- tz.transition 1987, 9, :o2, 559663200
- tz.transition 1988, 3, :o3, 575388000
- tz.transition 1988, 9, :o2, 591112800
- tz.transition 1989, 3, :o3, 606837600
- tz.transition 1989, 9, :o2, 622562400
- tz.transition 1990, 3, :o3, 638287200
- tz.transition 1990, 9, :o2, 654616800
- tz.transition 1991, 3, :o4, 670341600
- tz.transition 1991, 9, :o1, 686070000
- tz.transition 1992, 1, :o2, 695746800
- tz.transition 1992, 3, :o3, 701780400
- tz.transition 1992, 9, :o2, 717501600
- tz.transition 1993, 3, :o3, 733240800
- tz.transition 1993, 9, :o2, 748965600
- tz.transition 1994, 3, :o3, 764690400
- tz.transition 1994, 9, :o2, 780415200
- tz.transition 1995, 3, :o3, 796140000
- tz.transition 1995, 9, :o2, 811864800
- tz.transition 1996, 3, :o3, 828194400
- tz.transition 1996, 10, :o2, 846338400
- tz.transition 1997, 3, :o3, 859644000
- tz.transition 1997, 10, :o2, 877788000
- tz.transition 1998, 3, :o3, 891093600
- tz.transition 1998, 10, :o2, 909237600
- tz.transition 1999, 3, :o3, 922543200
- tz.transition 1999, 10, :o2, 941292000
- tz.transition 2000, 3, :o3, 953992800
- tz.transition 2000, 10, :o2, 972741600
- tz.transition 2001, 3, :o3, 985442400
- tz.transition 2001, 10, :o2, 1004191200
- tz.transition 2002, 3, :o3, 1017496800
- tz.transition 2002, 10, :o2, 1035640800
- tz.transition 2003, 3, :o3, 1048946400
- tz.transition 2003, 10, :o2, 1067090400
- tz.transition 2004, 3, :o3, 1080396000
- tz.transition 2004, 10, :o2, 1099144800
- tz.transition 2005, 3, :o3, 1111845600
- tz.transition 2005, 10, :o2, 1130594400
- tz.transition 2006, 3, :o3, 1143295200
- tz.transition 2006, 10, :o2, 1162044000
- tz.transition 2007, 3, :o3, 1174744800
- tz.transition 2007, 10, :o2, 1193493600
- tz.transition 2008, 3, :o3, 1206799200
- tz.transition 2008, 10, :o2, 1224943200
- tz.transition 2009, 3, :o3, 1238248800
- tz.transition 2009, 10, :o2, 1256392800
- tz.transition 2010, 3, :o3, 1269698400
- tz.transition 2010, 10, :o2, 1288447200
- tz.transition 2011, 3, :o3, 1301148000
- tz.transition 2011, 10, :o2, 1319896800
- tz.transition 2012, 3, :o3, 1332597600
- tz.transition 2012, 10, :o2, 1351346400
- tz.transition 2013, 3, :o3, 1364652000
- tz.transition 2013, 10, :o2, 1382796000
- tz.transition 2014, 3, :o3, 1396101600
- tz.transition 2014, 10, :o2, 1414245600
- tz.transition 2015, 3, :o3, 1427551200
- tz.transition 2015, 10, :o2, 1445695200
- tz.transition 2016, 3, :o3, 1459000800
- tz.transition 2016, 10, :o2, 1477749600
- tz.transition 2017, 3, :o3, 1490450400
- tz.transition 2017, 10, :o2, 1509199200
- tz.transition 2018, 3, :o3, 1521900000
- tz.transition 2018, 10, :o2, 1540648800
- tz.transition 2019, 3, :o3, 1553954400
- tz.transition 2019, 10, :o2, 1572098400
- tz.transition 2020, 3, :o3, 1585404000
- tz.transition 2020, 10, :o2, 1603548000
- tz.transition 2021, 3, :o3, 1616853600
- tz.transition 2021, 10, :o2, 1635602400
- tz.transition 2022, 3, :o3, 1648303200
- tz.transition 2022, 10, :o2, 1667052000
- tz.transition 2023, 3, :o3, 1679752800
- tz.transition 2023, 10, :o2, 1698501600
- tz.transition 2024, 3, :o3, 1711807200
- tz.transition 2024, 10, :o2, 1729951200
- tz.transition 2025, 3, :o3, 1743256800
- tz.transition 2025, 10, :o2, 1761400800
- tz.transition 2026, 3, :o3, 1774706400
- tz.transition 2026, 10, :o2, 1792850400
- tz.transition 2027, 3, :o3, 1806156000
- tz.transition 2027, 10, :o2, 1824904800
- tz.transition 2028, 3, :o3, 1837605600
- tz.transition 2028, 10, :o2, 1856354400
- tz.transition 2029, 3, :o3, 1869055200
- tz.transition 2029, 10, :o2, 1887804000
- tz.transition 2030, 3, :o3, 1901109600
- tz.transition 2030, 10, :o2, 1919253600
- tz.transition 2031, 3, :o3, 1932559200
- tz.transition 2031, 10, :o2, 1950703200
- tz.transition 2032, 3, :o3, 1964008800
- tz.transition 2032, 10, :o2, 1982757600
- tz.transition 2033, 3, :o3, 1995458400
- tz.transition 2033, 10, :o2, 2014207200
- tz.transition 2034, 3, :o3, 2026908000
- tz.transition 2034, 10, :o2, 2045656800
- tz.transition 2035, 3, :o3, 2058357600
- tz.transition 2035, 10, :o2, 2077106400
- tz.transition 2036, 3, :o3, 2090412000
- tz.transition 2036, 10, :o2, 2108556000
- tz.transition 2037, 3, :o3, 2121861600
- tz.transition 2037, 10, :o2, 2140005600
- tz.transition 2038, 3, :o3, 29586121, 12
- tz.transition 2038, 10, :o2, 29588725, 12
- tz.transition 2039, 3, :o3, 29590489, 12
- tz.transition 2039, 10, :o2, 29593093, 12
- tz.transition 2040, 3, :o3, 29594857, 12
- tz.transition 2040, 10, :o2, 29597461, 12
- tz.transition 2041, 3, :o3, 29599309, 12
- tz.transition 2041, 10, :o2, 29601829, 12
- tz.transition 2042, 3, :o3, 29603677, 12
- tz.transition 2042, 10, :o2, 29606197, 12
- tz.transition 2043, 3, :o3, 29608045, 12
- tz.transition 2043, 10, :o2, 29610565, 12
- tz.transition 2044, 3, :o3, 29612413, 12
- tz.transition 2044, 10, :o2, 29615017, 12
- tz.transition 2045, 3, :o3, 29616781, 12
- tz.transition 2045, 10, :o2, 29619385, 12
- tz.transition 2046, 3, :o3, 29621149, 12
- tz.transition 2046, 10, :o2, 29623753, 12
- tz.transition 2047, 3, :o3, 29625601, 12
- tz.transition 2047, 10, :o2, 29628121, 12
- tz.transition 2048, 3, :o3, 29629969, 12
- tz.transition 2048, 10, :o2, 29632489, 12
- tz.transition 2049, 3, :o3, 29634337, 12
- tz.transition 2049, 10, :o2, 29636941, 12
- tz.transition 2050, 3, :o3, 29638705, 12
- tz.transition 2050, 10, :o2, 29641309, 12
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Karachi.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Karachi.rb
deleted file mode 100644
index dfe02c5cf6..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Karachi.rb
+++ /dev/null
@@ -1,114 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Karachi
- include TimezoneDefinition
-
- timezone 'Asia/Karachi' do |tz|
- tz.offset :o0, 16092, 0, :LMT
- tz.offset :o1, 19800, 0, :IST
- tz.offset :o2, 19800, 3600, :IST
- tz.offset :o3, 18000, 0, :KART
- tz.offset :o4, 18000, 0, :PKT
- tz.offset :o5, 18000, 3600, :PKST
-
- tz.transition 1906, 12, :o1, 1934061051, 800
- tz.transition 1942, 8, :o2, 116668957, 48
- tz.transition 1945, 10, :o1, 116723675, 48
- tz.transition 1951, 9, :o3, 116828125, 48
- tz.transition 1971, 3, :o4, 38775600
- tz.transition 2002, 4, :o5, 1018119660
- tz.transition 2002, 10, :o4, 1033840860
- tz.transition 2008, 5, :o5, 1212260400
- tz.transition 2008, 10, :o4, 1225476000
- tz.transition 2009, 4, :o5, 1239735600
- tz.transition 2009, 10, :o4, 1257012000
- tz.transition 2010, 4, :o5, 1271271600
- tz.transition 2010, 10, :o4, 1288548000
- tz.transition 2011, 4, :o5, 1302807600
- tz.transition 2011, 10, :o4, 1320084000
- tz.transition 2012, 4, :o5, 1334430000
- tz.transition 2012, 10, :o4, 1351706400
- tz.transition 2013, 4, :o5, 1365966000
- tz.transition 2013, 10, :o4, 1383242400
- tz.transition 2014, 4, :o5, 1397502000
- tz.transition 2014, 10, :o4, 1414778400
- tz.transition 2015, 4, :o5, 1429038000
- tz.transition 2015, 10, :o4, 1446314400
- tz.transition 2016, 4, :o5, 1460660400
- tz.transition 2016, 10, :o4, 1477936800
- tz.transition 2017, 4, :o5, 1492196400
- tz.transition 2017, 10, :o4, 1509472800
- tz.transition 2018, 4, :o5, 1523732400
- tz.transition 2018, 10, :o4, 1541008800
- tz.transition 2019, 4, :o5, 1555268400
- tz.transition 2019, 10, :o4, 1572544800
- tz.transition 2020, 4, :o5, 1586890800
- tz.transition 2020, 10, :o4, 1604167200
- tz.transition 2021, 4, :o5, 1618426800
- tz.transition 2021, 10, :o4, 1635703200
- tz.transition 2022, 4, :o5, 1649962800
- tz.transition 2022, 10, :o4, 1667239200
- tz.transition 2023, 4, :o5, 1681498800
- tz.transition 2023, 10, :o4, 1698775200
- tz.transition 2024, 4, :o5, 1713121200
- tz.transition 2024, 10, :o4, 1730397600
- tz.transition 2025, 4, :o5, 1744657200
- tz.transition 2025, 10, :o4, 1761933600
- tz.transition 2026, 4, :o5, 1776193200
- tz.transition 2026, 10, :o4, 1793469600
- tz.transition 2027, 4, :o5, 1807729200
- tz.transition 2027, 10, :o4, 1825005600
- tz.transition 2028, 4, :o5, 1839351600
- tz.transition 2028, 10, :o4, 1856628000
- tz.transition 2029, 4, :o5, 1870887600
- tz.transition 2029, 10, :o4, 1888164000
- tz.transition 2030, 4, :o5, 1902423600
- tz.transition 2030, 10, :o4, 1919700000
- tz.transition 2031, 4, :o5, 1933959600
- tz.transition 2031, 10, :o4, 1951236000
- tz.transition 2032, 4, :o5, 1965582000
- tz.transition 2032, 10, :o4, 1982858400
- tz.transition 2033, 4, :o5, 1997118000
- tz.transition 2033, 10, :o4, 2014394400
- tz.transition 2034, 4, :o5, 2028654000
- tz.transition 2034, 10, :o4, 2045930400
- tz.transition 2035, 4, :o5, 2060190000
- tz.transition 2035, 10, :o4, 2077466400
- tz.transition 2036, 4, :o5, 2091812400
- tz.transition 2036, 10, :o4, 2109088800
- tz.transition 2037, 4, :o5, 2123348400
- tz.transition 2037, 10, :o4, 2140624800
- tz.transition 2038, 4, :o5, 59172679, 24
- tz.transition 2038, 10, :o4, 9862913, 4
- tz.transition 2039, 4, :o5, 59181439, 24
- tz.transition 2039, 10, :o4, 9864373, 4
- tz.transition 2040, 4, :o5, 59190223, 24
- tz.transition 2040, 10, :o4, 9865837, 4
- tz.transition 2041, 4, :o5, 59198983, 24
- tz.transition 2041, 10, :o4, 9867297, 4
- tz.transition 2042, 4, :o5, 59207743, 24
- tz.transition 2042, 10, :o4, 9868757, 4
- tz.transition 2043, 4, :o5, 59216503, 24
- tz.transition 2043, 10, :o4, 9870217, 4
- tz.transition 2044, 4, :o5, 59225287, 24
- tz.transition 2044, 10, :o4, 9871681, 4
- tz.transition 2045, 4, :o5, 59234047, 24
- tz.transition 2045, 10, :o4, 9873141, 4
- tz.transition 2046, 4, :o5, 59242807, 24
- tz.transition 2046, 10, :o4, 9874601, 4
- tz.transition 2047, 4, :o5, 59251567, 24
- tz.transition 2047, 10, :o4, 9876061, 4
- tz.transition 2048, 4, :o5, 59260351, 24
- tz.transition 2048, 10, :o4, 9877525, 4
- tz.transition 2049, 4, :o5, 59269111, 24
- tz.transition 2049, 10, :o4, 9878985, 4
- tz.transition 2050, 4, :o5, 59277871, 24
- tz.transition 2050, 10, :o4, 9880445, 4
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kathmandu.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kathmandu.rb
deleted file mode 100644
index 37b241612e..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kathmandu.rb
+++ /dev/null
@@ -1,20 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Kathmandu
- include TimezoneDefinition
-
- timezone 'Asia/Kathmandu' do |tz|
- tz.offset :o0, 20476, 0, :LMT
- tz.offset :o1, 19800, 0, :IST
- tz.offset :o2, 20700, 0, :NPT
-
- tz.transition 1919, 12, :o1, 52322204081, 21600
- tz.transition 1985, 12, :o2, 504901800
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kolkata.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kolkata.rb
deleted file mode 100644
index 1b6ffbd59d..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kolkata.rb
+++ /dev/null
@@ -1,25 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Kolkata
- include TimezoneDefinition
-
- timezone 'Asia/Kolkata' do |tz|
- tz.offset :o0, 21208, 0, :LMT
- tz.offset :o1, 21200, 0, :HMT
- tz.offset :o2, 23400, 0, :BURT
- tz.offset :o3, 19800, 0, :IST
- tz.offset :o4, 19800, 3600, :IST
-
- tz.transition 1879, 12, :o1, 26003324749, 10800
- tz.transition 1941, 9, :o2, 524937943, 216
- tz.transition 1942, 5, :o3, 116663723, 48
- tz.transition 1942, 8, :o4, 116668957, 48
- tz.transition 1945, 10, :o3, 116723675, 48
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Krasnoyarsk.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Krasnoyarsk.rb
deleted file mode 100644
index d6c503c155..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Krasnoyarsk.rb
+++ /dev/null
@@ -1,163 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Krasnoyarsk
- include TimezoneDefinition
-
- timezone 'Asia/Krasnoyarsk' do |tz|
- tz.offset :o0, 22280, 0, :LMT
- tz.offset :o1, 21600, 0, :KRAT
- tz.offset :o2, 25200, 0, :KRAT
- tz.offset :o3, 25200, 3600, :KRAST
- tz.offset :o4, 21600, 3600, :KRAST
-
- tz.transition 1920, 1, :o1, 5232231163, 2160
- tz.transition 1930, 6, :o2, 9704593, 4
- tz.transition 1981, 3, :o3, 354906000
- tz.transition 1981, 9, :o2, 370713600
- tz.transition 1982, 3, :o3, 386442000
- tz.transition 1982, 9, :o2, 402249600
- tz.transition 1983, 3, :o3, 417978000
- tz.transition 1983, 9, :o2, 433785600
- tz.transition 1984, 3, :o3, 449600400
- tz.transition 1984, 9, :o2, 465332400
- tz.transition 1985, 3, :o3, 481057200
- tz.transition 1985, 9, :o2, 496782000
- tz.transition 1986, 3, :o3, 512506800
- tz.transition 1986, 9, :o2, 528231600
- tz.transition 1987, 3, :o3, 543956400
- tz.transition 1987, 9, :o2, 559681200
- tz.transition 1988, 3, :o3, 575406000
- tz.transition 1988, 9, :o2, 591130800
- tz.transition 1989, 3, :o3, 606855600
- tz.transition 1989, 9, :o2, 622580400
- tz.transition 1990, 3, :o3, 638305200
- tz.transition 1990, 9, :o2, 654634800
- tz.transition 1991, 3, :o4, 670359600
- tz.transition 1991, 9, :o1, 686088000
- tz.transition 1992, 1, :o2, 695764800
- tz.transition 1992, 3, :o3, 701798400
- tz.transition 1992, 9, :o2, 717519600
- tz.transition 1993, 3, :o3, 733258800
- tz.transition 1993, 9, :o2, 748983600
- tz.transition 1994, 3, :o3, 764708400
- tz.transition 1994, 9, :o2, 780433200
- tz.transition 1995, 3, :o3, 796158000
- tz.transition 1995, 9, :o2, 811882800
- tz.transition 1996, 3, :o3, 828212400
- tz.transition 1996, 10, :o2, 846356400
- tz.transition 1997, 3, :o3, 859662000
- tz.transition 1997, 10, :o2, 877806000
- tz.transition 1998, 3, :o3, 891111600
- tz.transition 1998, 10, :o2, 909255600
- tz.transition 1999, 3, :o3, 922561200
- tz.transition 1999, 10, :o2, 941310000
- tz.transition 2000, 3, :o3, 954010800
- tz.transition 2000, 10, :o2, 972759600
- tz.transition 2001, 3, :o3, 985460400
- tz.transition 2001, 10, :o2, 1004209200
- tz.transition 2002, 3, :o3, 1017514800
- tz.transition 2002, 10, :o2, 1035658800
- tz.transition 2003, 3, :o3, 1048964400
- tz.transition 2003, 10, :o2, 1067108400
- tz.transition 2004, 3, :o3, 1080414000
- tz.transition 2004, 10, :o2, 1099162800
- tz.transition 2005, 3, :o3, 1111863600
- tz.transition 2005, 10, :o2, 1130612400
- tz.transition 2006, 3, :o3, 1143313200
- tz.transition 2006, 10, :o2, 1162062000
- tz.transition 2007, 3, :o3, 1174762800
- tz.transition 2007, 10, :o2, 1193511600
- tz.transition 2008, 3, :o3, 1206817200
- tz.transition 2008, 10, :o2, 1224961200
- tz.transition 2009, 3, :o3, 1238266800
- tz.transition 2009, 10, :o2, 1256410800
- tz.transition 2010, 3, :o3, 1269716400
- tz.transition 2010, 10, :o2, 1288465200
- tz.transition 2011, 3, :o3, 1301166000
- tz.transition 2011, 10, :o2, 1319914800
- tz.transition 2012, 3, :o3, 1332615600
- tz.transition 2012, 10, :o2, 1351364400
- tz.transition 2013, 3, :o3, 1364670000
- tz.transition 2013, 10, :o2, 1382814000
- tz.transition 2014, 3, :o3, 1396119600
- tz.transition 2014, 10, :o2, 1414263600
- tz.transition 2015, 3, :o3, 1427569200
- tz.transition 2015, 10, :o2, 1445713200
- tz.transition 2016, 3, :o3, 1459018800
- tz.transition 2016, 10, :o2, 1477767600
- tz.transition 2017, 3, :o3, 1490468400
- tz.transition 2017, 10, :o2, 1509217200
- tz.transition 2018, 3, :o3, 1521918000
- tz.transition 2018, 10, :o2, 1540666800
- tz.transition 2019, 3, :o3, 1553972400
- tz.transition 2019, 10, :o2, 1572116400
- tz.transition 2020, 3, :o3, 1585422000
- tz.transition 2020, 10, :o2, 1603566000
- tz.transition 2021, 3, :o3, 1616871600
- tz.transition 2021, 10, :o2, 1635620400
- tz.transition 2022, 3, :o3, 1648321200
- tz.transition 2022, 10, :o2, 1667070000
- tz.transition 2023, 3, :o3, 1679770800
- tz.transition 2023, 10, :o2, 1698519600
- tz.transition 2024, 3, :o3, 1711825200
- tz.transition 2024, 10, :o2, 1729969200
- tz.transition 2025, 3, :o3, 1743274800
- tz.transition 2025, 10, :o2, 1761418800
- tz.transition 2026, 3, :o3, 1774724400
- tz.transition 2026, 10, :o2, 1792868400
- tz.transition 2027, 3, :o3, 1806174000
- tz.transition 2027, 10, :o2, 1824922800
- tz.transition 2028, 3, :o3, 1837623600
- tz.transition 2028, 10, :o2, 1856372400
- tz.transition 2029, 3, :o3, 1869073200
- tz.transition 2029, 10, :o2, 1887822000
- tz.transition 2030, 3, :o3, 1901127600
- tz.transition 2030, 10, :o2, 1919271600
- tz.transition 2031, 3, :o3, 1932577200
- tz.transition 2031, 10, :o2, 1950721200
- tz.transition 2032, 3, :o3, 1964026800
- tz.transition 2032, 10, :o2, 1982775600
- tz.transition 2033, 3, :o3, 1995476400
- tz.transition 2033, 10, :o2, 2014225200
- tz.transition 2034, 3, :o3, 2026926000
- tz.transition 2034, 10, :o2, 2045674800
- tz.transition 2035, 3, :o3, 2058375600
- tz.transition 2035, 10, :o2, 2077124400
- tz.transition 2036, 3, :o3, 2090430000
- tz.transition 2036, 10, :o2, 2108574000
- tz.transition 2037, 3, :o3, 2121879600
- tz.transition 2037, 10, :o2, 2140023600
- tz.transition 2038, 3, :o3, 59172247, 24
- tz.transition 2038, 10, :o2, 59177455, 24
- tz.transition 2039, 3, :o3, 59180983, 24
- tz.transition 2039, 10, :o2, 59186191, 24
- tz.transition 2040, 3, :o3, 59189719, 24
- tz.transition 2040, 10, :o2, 59194927, 24
- tz.transition 2041, 3, :o3, 59198623, 24
- tz.transition 2041, 10, :o2, 59203663, 24
- tz.transition 2042, 3, :o3, 59207359, 24
- tz.transition 2042, 10, :o2, 59212399, 24
- tz.transition 2043, 3, :o3, 59216095, 24
- tz.transition 2043, 10, :o2, 59221135, 24
- tz.transition 2044, 3, :o3, 59224831, 24
- tz.transition 2044, 10, :o2, 59230039, 24
- tz.transition 2045, 3, :o3, 59233567, 24
- tz.transition 2045, 10, :o2, 59238775, 24
- tz.transition 2046, 3, :o3, 59242303, 24
- tz.transition 2046, 10, :o2, 59247511, 24
- tz.transition 2047, 3, :o3, 59251207, 24
- tz.transition 2047, 10, :o2, 59256247, 24
- tz.transition 2048, 3, :o3, 59259943, 24
- tz.transition 2048, 10, :o2, 59264983, 24
- tz.transition 2049, 3, :o3, 59268679, 24
- tz.transition 2049, 10, :o2, 59273887, 24
- tz.transition 2050, 3, :o3, 59277415, 24
- tz.transition 2050, 10, :o2, 59282623, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kuala_Lumpur.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kuala_Lumpur.rb
deleted file mode 100644
index 77a0c206fa..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kuala_Lumpur.rb
+++ /dev/null
@@ -1,31 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Kuala_Lumpur
- include TimezoneDefinition
-
- timezone 'Asia/Kuala_Lumpur' do |tz|
- tz.offset :o0, 24406, 0, :LMT
- tz.offset :o1, 24925, 0, :SMT
- tz.offset :o2, 25200, 0, :MALT
- tz.offset :o3, 25200, 1200, :MALST
- tz.offset :o4, 26400, 0, :MALT
- tz.offset :o5, 27000, 0, :MALT
- tz.offset :o6, 32400, 0, :JST
- tz.offset :o7, 28800, 0, :MYT
-
- tz.transition 1900, 12, :o1, 104344641397, 43200
- tz.transition 1905, 5, :o2, 8353142363, 3456
- tz.transition 1932, 12, :o3, 58249757, 24
- tz.transition 1935, 12, :o4, 87414055, 36
- tz.transition 1941, 8, :o5, 87488575, 36
- tz.transition 1942, 2, :o6, 38886499, 16
- tz.transition 1945, 9, :o5, 19453681, 8
- tz.transition 1981, 12, :o7, 378664200
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kuwait.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kuwait.rb
deleted file mode 100644
index 5bd5283197..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Kuwait.rb
+++ /dev/null
@@ -1,18 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Kuwait
- include TimezoneDefinition
-
- timezone 'Asia/Kuwait' do |tz|
- tz.offset :o0, 11516, 0, :LMT
- tz.offset :o1, 10800, 0, :AST
-
- tz.transition 1949, 12, :o1, 52558899121, 21600
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Magadan.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Magadan.rb
deleted file mode 100644
index 302093693e..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Magadan.rb
+++ /dev/null
@@ -1,163 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Magadan
- include TimezoneDefinition
-
- timezone 'Asia/Magadan' do |tz|
- tz.offset :o0, 36192, 0, :LMT
- tz.offset :o1, 36000, 0, :MAGT
- tz.offset :o2, 39600, 0, :MAGT
- tz.offset :o3, 39600, 3600, :MAGST
- tz.offset :o4, 36000, 3600, :MAGST
-
- tz.transition 1924, 5, :o1, 2181516373, 900
- tz.transition 1930, 6, :o2, 29113777, 12
- tz.transition 1981, 3, :o3, 354891600
- tz.transition 1981, 9, :o2, 370699200
- tz.transition 1982, 3, :o3, 386427600
- tz.transition 1982, 9, :o2, 402235200
- tz.transition 1983, 3, :o3, 417963600
- tz.transition 1983, 9, :o2, 433771200
- tz.transition 1984, 3, :o3, 449586000
- tz.transition 1984, 9, :o2, 465318000
- tz.transition 1985, 3, :o3, 481042800
- tz.transition 1985, 9, :o2, 496767600
- tz.transition 1986, 3, :o3, 512492400
- tz.transition 1986, 9, :o2, 528217200
- tz.transition 1987, 3, :o3, 543942000
- tz.transition 1987, 9, :o2, 559666800
- tz.transition 1988, 3, :o3, 575391600
- tz.transition 1988, 9, :o2, 591116400
- tz.transition 1989, 3, :o3, 606841200
- tz.transition 1989, 9, :o2, 622566000
- tz.transition 1990, 3, :o3, 638290800
- tz.transition 1990, 9, :o2, 654620400
- tz.transition 1991, 3, :o4, 670345200
- tz.transition 1991, 9, :o1, 686073600
- tz.transition 1992, 1, :o2, 695750400
- tz.transition 1992, 3, :o3, 701784000
- tz.transition 1992, 9, :o2, 717505200
- tz.transition 1993, 3, :o3, 733244400
- tz.transition 1993, 9, :o2, 748969200
- tz.transition 1994, 3, :o3, 764694000
- tz.transition 1994, 9, :o2, 780418800
- tz.transition 1995, 3, :o3, 796143600
- tz.transition 1995, 9, :o2, 811868400
- tz.transition 1996, 3, :o3, 828198000
- tz.transition 1996, 10, :o2, 846342000
- tz.transition 1997, 3, :o3, 859647600
- tz.transition 1997, 10, :o2, 877791600
- tz.transition 1998, 3, :o3, 891097200
- tz.transition 1998, 10, :o2, 909241200
- tz.transition 1999, 3, :o3, 922546800
- tz.transition 1999, 10, :o2, 941295600
- tz.transition 2000, 3, :o3, 953996400
- tz.transition 2000, 10, :o2, 972745200
- tz.transition 2001, 3, :o3, 985446000
- tz.transition 2001, 10, :o2, 1004194800
- tz.transition 2002, 3, :o3, 1017500400
- tz.transition 2002, 10, :o2, 1035644400
- tz.transition 2003, 3, :o3, 1048950000
- tz.transition 2003, 10, :o2, 1067094000
- tz.transition 2004, 3, :o3, 1080399600
- tz.transition 2004, 10, :o2, 1099148400
- tz.transition 2005, 3, :o3, 1111849200
- tz.transition 2005, 10, :o2, 1130598000
- tz.transition 2006, 3, :o3, 1143298800
- tz.transition 2006, 10, :o2, 1162047600
- tz.transition 2007, 3, :o3, 1174748400
- tz.transition 2007, 10, :o2, 1193497200
- tz.transition 2008, 3, :o3, 1206802800
- tz.transition 2008, 10, :o2, 1224946800
- tz.transition 2009, 3, :o3, 1238252400
- tz.transition 2009, 10, :o2, 1256396400
- tz.transition 2010, 3, :o3, 1269702000
- tz.transition 2010, 10, :o2, 1288450800
- tz.transition 2011, 3, :o3, 1301151600
- tz.transition 2011, 10, :o2, 1319900400
- tz.transition 2012, 3, :o3, 1332601200
- tz.transition 2012, 10, :o2, 1351350000
- tz.transition 2013, 3, :o3, 1364655600
- tz.transition 2013, 10, :o2, 1382799600
- tz.transition 2014, 3, :o3, 1396105200
- tz.transition 2014, 10, :o2, 1414249200
- tz.transition 2015, 3, :o3, 1427554800
- tz.transition 2015, 10, :o2, 1445698800
- tz.transition 2016, 3, :o3, 1459004400
- tz.transition 2016, 10, :o2, 1477753200
- tz.transition 2017, 3, :o3, 1490454000
- tz.transition 2017, 10, :o2, 1509202800
- tz.transition 2018, 3, :o3, 1521903600
- tz.transition 2018, 10, :o2, 1540652400
- tz.transition 2019, 3, :o3, 1553958000
- tz.transition 2019, 10, :o2, 1572102000
- tz.transition 2020, 3, :o3, 1585407600
- tz.transition 2020, 10, :o2, 1603551600
- tz.transition 2021, 3, :o3, 1616857200
- tz.transition 2021, 10, :o2, 1635606000
- tz.transition 2022, 3, :o3, 1648306800
- tz.transition 2022, 10, :o2, 1667055600
- tz.transition 2023, 3, :o3, 1679756400
- tz.transition 2023, 10, :o2, 1698505200
- tz.transition 2024, 3, :o3, 1711810800
- tz.transition 2024, 10, :o2, 1729954800
- tz.transition 2025, 3, :o3, 1743260400
- tz.transition 2025, 10, :o2, 1761404400
- tz.transition 2026, 3, :o3, 1774710000
- tz.transition 2026, 10, :o2, 1792854000
- tz.transition 2027, 3, :o3, 1806159600
- tz.transition 2027, 10, :o2, 1824908400
- tz.transition 2028, 3, :o3, 1837609200
- tz.transition 2028, 10, :o2, 1856358000
- tz.transition 2029, 3, :o3, 1869058800
- tz.transition 2029, 10, :o2, 1887807600
- tz.transition 2030, 3, :o3, 1901113200
- tz.transition 2030, 10, :o2, 1919257200
- tz.transition 2031, 3, :o3, 1932562800
- tz.transition 2031, 10, :o2, 1950706800
- tz.transition 2032, 3, :o3, 1964012400
- tz.transition 2032, 10, :o2, 1982761200
- tz.transition 2033, 3, :o3, 1995462000
- tz.transition 2033, 10, :o2, 2014210800
- tz.transition 2034, 3, :o3, 2026911600
- tz.transition 2034, 10, :o2, 2045660400
- tz.transition 2035, 3, :o3, 2058361200
- tz.transition 2035, 10, :o2, 2077110000
- tz.transition 2036, 3, :o3, 2090415600
- tz.transition 2036, 10, :o2, 2108559600
- tz.transition 2037, 3, :o3, 2121865200
- tz.transition 2037, 10, :o2, 2140009200
- tz.transition 2038, 3, :o3, 19724081, 8
- tz.transition 2038, 10, :o2, 19725817, 8
- tz.transition 2039, 3, :o3, 19726993, 8
- tz.transition 2039, 10, :o2, 19728729, 8
- tz.transition 2040, 3, :o3, 19729905, 8
- tz.transition 2040, 10, :o2, 19731641, 8
- tz.transition 2041, 3, :o3, 19732873, 8
- tz.transition 2041, 10, :o2, 19734553, 8
- tz.transition 2042, 3, :o3, 19735785, 8
- tz.transition 2042, 10, :o2, 19737465, 8
- tz.transition 2043, 3, :o3, 19738697, 8
- tz.transition 2043, 10, :o2, 19740377, 8
- tz.transition 2044, 3, :o3, 19741609, 8
- tz.transition 2044, 10, :o2, 19743345, 8
- tz.transition 2045, 3, :o3, 19744521, 8
- tz.transition 2045, 10, :o2, 19746257, 8
- tz.transition 2046, 3, :o3, 19747433, 8
- tz.transition 2046, 10, :o2, 19749169, 8
- tz.transition 2047, 3, :o3, 19750401, 8
- tz.transition 2047, 10, :o2, 19752081, 8
- tz.transition 2048, 3, :o3, 19753313, 8
- tz.transition 2048, 10, :o2, 19754993, 8
- tz.transition 2049, 3, :o3, 19756225, 8
- tz.transition 2049, 10, :o2, 19757961, 8
- tz.transition 2050, 3, :o3, 19759137, 8
- tz.transition 2050, 10, :o2, 19760873, 8
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Muscat.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Muscat.rb
deleted file mode 100644
index 604f651dfa..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Muscat.rb
+++ /dev/null
@@ -1,18 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Muscat
- include TimezoneDefinition
-
- timezone 'Asia/Muscat' do |tz|
- tz.offset :o0, 14060, 0, :LMT
- tz.offset :o1, 14400, 0, :GST
-
- tz.transition 1919, 12, :o1, 10464441137, 4320
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Novosibirsk.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Novosibirsk.rb
deleted file mode 100644
index a4e7796e75..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Novosibirsk.rb
+++ /dev/null
@@ -1,164 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Novosibirsk
- include TimezoneDefinition
-
- timezone 'Asia/Novosibirsk' do |tz|
- tz.offset :o0, 19900, 0, :LMT
- tz.offset :o1, 21600, 0, :NOVT
- tz.offset :o2, 25200, 0, :NOVT
- tz.offset :o3, 25200, 3600, :NOVST
- tz.offset :o4, 21600, 3600, :NOVST
-
- tz.transition 1919, 12, :o1, 2092872833, 864
- tz.transition 1930, 6, :o2, 9704593, 4
- tz.transition 1981, 3, :o3, 354906000
- tz.transition 1981, 9, :o2, 370713600
- tz.transition 1982, 3, :o3, 386442000
- tz.transition 1982, 9, :o2, 402249600
- tz.transition 1983, 3, :o3, 417978000
- tz.transition 1983, 9, :o2, 433785600
- tz.transition 1984, 3, :o3, 449600400
- tz.transition 1984, 9, :o2, 465332400
- tz.transition 1985, 3, :o3, 481057200
- tz.transition 1985, 9, :o2, 496782000
- tz.transition 1986, 3, :o3, 512506800
- tz.transition 1986, 9, :o2, 528231600
- tz.transition 1987, 3, :o3, 543956400
- tz.transition 1987, 9, :o2, 559681200
- tz.transition 1988, 3, :o3, 575406000
- tz.transition 1988, 9, :o2, 591130800
- tz.transition 1989, 3, :o3, 606855600
- tz.transition 1989, 9, :o2, 622580400
- tz.transition 1990, 3, :o3, 638305200
- tz.transition 1990, 9, :o2, 654634800
- tz.transition 1991, 3, :o4, 670359600
- tz.transition 1991, 9, :o1, 686088000
- tz.transition 1992, 1, :o2, 695764800
- tz.transition 1992, 3, :o3, 701798400
- tz.transition 1992, 9, :o2, 717519600
- tz.transition 1993, 3, :o3, 733258800
- tz.transition 1993, 5, :o4, 738086400
- tz.transition 1993, 9, :o1, 748987200
- tz.transition 1994, 3, :o4, 764712000
- tz.transition 1994, 9, :o1, 780436800
- tz.transition 1995, 3, :o4, 796161600
- tz.transition 1995, 9, :o1, 811886400
- tz.transition 1996, 3, :o4, 828216000
- tz.transition 1996, 10, :o1, 846360000
- tz.transition 1997, 3, :o4, 859665600
- tz.transition 1997, 10, :o1, 877809600
- tz.transition 1998, 3, :o4, 891115200
- tz.transition 1998, 10, :o1, 909259200
- tz.transition 1999, 3, :o4, 922564800
- tz.transition 1999, 10, :o1, 941313600
- tz.transition 2000, 3, :o4, 954014400
- tz.transition 2000, 10, :o1, 972763200
- tz.transition 2001, 3, :o4, 985464000
- tz.transition 2001, 10, :o1, 1004212800
- tz.transition 2002, 3, :o4, 1017518400
- tz.transition 2002, 10, :o1, 1035662400
- tz.transition 2003, 3, :o4, 1048968000
- tz.transition 2003, 10, :o1, 1067112000
- tz.transition 2004, 3, :o4, 1080417600
- tz.transition 2004, 10, :o1, 1099166400
- tz.transition 2005, 3, :o4, 1111867200
- tz.transition 2005, 10, :o1, 1130616000
- tz.transition 2006, 3, :o4, 1143316800
- tz.transition 2006, 10, :o1, 1162065600
- tz.transition 2007, 3, :o4, 1174766400
- tz.transition 2007, 10, :o1, 1193515200
- tz.transition 2008, 3, :o4, 1206820800
- tz.transition 2008, 10, :o1, 1224964800
- tz.transition 2009, 3, :o4, 1238270400
- tz.transition 2009, 10, :o1, 1256414400
- tz.transition 2010, 3, :o4, 1269720000
- tz.transition 2010, 10, :o1, 1288468800
- tz.transition 2011, 3, :o4, 1301169600
- tz.transition 2011, 10, :o1, 1319918400
- tz.transition 2012, 3, :o4, 1332619200
- tz.transition 2012, 10, :o1, 1351368000
- tz.transition 2013, 3, :o4, 1364673600
- tz.transition 2013, 10, :o1, 1382817600
- tz.transition 2014, 3, :o4, 1396123200
- tz.transition 2014, 10, :o1, 1414267200
- tz.transition 2015, 3, :o4, 1427572800
- tz.transition 2015, 10, :o1, 1445716800
- tz.transition 2016, 3, :o4, 1459022400
- tz.transition 2016, 10, :o1, 1477771200
- tz.transition 2017, 3, :o4, 1490472000
- tz.transition 2017, 10, :o1, 1509220800
- tz.transition 2018, 3, :o4, 1521921600
- tz.transition 2018, 10, :o1, 1540670400
- tz.transition 2019, 3, :o4, 1553976000
- tz.transition 2019, 10, :o1, 1572120000
- tz.transition 2020, 3, :o4, 1585425600
- tz.transition 2020, 10, :o1, 1603569600
- tz.transition 2021, 3, :o4, 1616875200
- tz.transition 2021, 10, :o1, 1635624000
- tz.transition 2022, 3, :o4, 1648324800
- tz.transition 2022, 10, :o1, 1667073600
- tz.transition 2023, 3, :o4, 1679774400
- tz.transition 2023, 10, :o1, 1698523200
- tz.transition 2024, 3, :o4, 1711828800
- tz.transition 2024, 10, :o1, 1729972800
- tz.transition 2025, 3, :o4, 1743278400
- tz.transition 2025, 10, :o1, 1761422400
- tz.transition 2026, 3, :o4, 1774728000
- tz.transition 2026, 10, :o1, 1792872000
- tz.transition 2027, 3, :o4, 1806177600
- tz.transition 2027, 10, :o1, 1824926400
- tz.transition 2028, 3, :o4, 1837627200
- tz.transition 2028, 10, :o1, 1856376000
- tz.transition 2029, 3, :o4, 1869076800
- tz.transition 2029, 10, :o1, 1887825600
- tz.transition 2030, 3, :o4, 1901131200
- tz.transition 2030, 10, :o1, 1919275200
- tz.transition 2031, 3, :o4, 1932580800
- tz.transition 2031, 10, :o1, 1950724800
- tz.transition 2032, 3, :o4, 1964030400
- tz.transition 2032, 10, :o1, 1982779200
- tz.transition 2033, 3, :o4, 1995480000
- tz.transition 2033, 10, :o1, 2014228800
- tz.transition 2034, 3, :o4, 2026929600
- tz.transition 2034, 10, :o1, 2045678400
- tz.transition 2035, 3, :o4, 2058379200
- tz.transition 2035, 10, :o1, 2077128000
- tz.transition 2036, 3, :o4, 2090433600
- tz.transition 2036, 10, :o1, 2108577600
- tz.transition 2037, 3, :o4, 2121883200
- tz.transition 2037, 10, :o1, 2140027200
- tz.transition 2038, 3, :o4, 7396531, 3
- tz.transition 2038, 10, :o1, 7397182, 3
- tz.transition 2039, 3, :o4, 7397623, 3
- tz.transition 2039, 10, :o1, 7398274, 3
- tz.transition 2040, 3, :o4, 7398715, 3
- tz.transition 2040, 10, :o1, 7399366, 3
- tz.transition 2041, 3, :o4, 7399828, 3
- tz.transition 2041, 10, :o1, 7400458, 3
- tz.transition 2042, 3, :o4, 7400920, 3
- tz.transition 2042, 10, :o1, 7401550, 3
- tz.transition 2043, 3, :o4, 7402012, 3
- tz.transition 2043, 10, :o1, 7402642, 3
- tz.transition 2044, 3, :o4, 7403104, 3
- tz.transition 2044, 10, :o1, 7403755, 3
- tz.transition 2045, 3, :o4, 7404196, 3
- tz.transition 2045, 10, :o1, 7404847, 3
- tz.transition 2046, 3, :o4, 7405288, 3
- tz.transition 2046, 10, :o1, 7405939, 3
- tz.transition 2047, 3, :o4, 7406401, 3
- tz.transition 2047, 10, :o1, 7407031, 3
- tz.transition 2048, 3, :o4, 7407493, 3
- tz.transition 2048, 10, :o1, 7408123, 3
- tz.transition 2049, 3, :o4, 7408585, 3
- tz.transition 2049, 10, :o1, 7409236, 3
- tz.transition 2050, 3, :o4, 7409677, 3
- tz.transition 2050, 10, :o1, 7410328, 3
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Rangoon.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Rangoon.rb
deleted file mode 100644
index 759b82d77a..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Rangoon.rb
+++ /dev/null
@@ -1,24 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Rangoon
- include TimezoneDefinition
-
- timezone 'Asia/Rangoon' do |tz|
- tz.offset :o0, 23080, 0, :LMT
- tz.offset :o1, 23076, 0, :RMT
- tz.offset :o2, 23400, 0, :BURT
- tz.offset :o3, 32400, 0, :JST
- tz.offset :o4, 23400, 0, :MMT
-
- tz.transition 1879, 12, :o1, 5200664903, 2160
- tz.transition 1919, 12, :o2, 5813578159, 2400
- tz.transition 1942, 4, :o3, 116663051, 48
- tz.transition 1945, 5, :o4, 19452625, 8
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Riyadh.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Riyadh.rb
deleted file mode 100644
index 7add410620..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Riyadh.rb
+++ /dev/null
@@ -1,18 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Riyadh
- include TimezoneDefinition
-
- timezone 'Asia/Riyadh' do |tz|
- tz.offset :o0, 11212, 0, :LMT
- tz.offset :o1, 10800, 0, :AST
-
- tz.transition 1949, 12, :o1, 52558899197, 21600
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Seoul.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Seoul.rb
deleted file mode 100644
index 795d2a75df..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Seoul.rb
+++ /dev/null
@@ -1,34 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Seoul
- include TimezoneDefinition
-
- timezone 'Asia/Seoul' do |tz|
- tz.offset :o0, 30472, 0, :LMT
- tz.offset :o1, 30600, 0, :KST
- tz.offset :o2, 32400, 0, :KST
- tz.offset :o3, 28800, 0, :KST
- tz.offset :o4, 28800, 3600, :KDT
- tz.offset :o5, 32400, 3600, :KDT
-
- tz.transition 1889, 12, :o1, 26042775991, 10800
- tz.transition 1904, 11, :o2, 116007127, 48
- tz.transition 1927, 12, :o1, 19401969, 8
- tz.transition 1931, 12, :o2, 116481943, 48
- tz.transition 1954, 3, :o3, 19478577, 8
- tz.transition 1960, 5, :o4, 14622415, 6
- tz.transition 1960, 9, :o3, 19497521, 8
- tz.transition 1961, 8, :o1, 14625127, 6
- tz.transition 1968, 9, :o2, 117126247, 48
- tz.transition 1987, 5, :o5, 547570800
- tz.transition 1987, 10, :o2, 560872800
- tz.transition 1988, 5, :o5, 579020400
- tz.transition 1988, 10, :o2, 592322400
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Shanghai.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Shanghai.rb
deleted file mode 100644
index 34b13d59ae..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Shanghai.rb
+++ /dev/null
@@ -1,35 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Shanghai
- include TimezoneDefinition
-
- timezone 'Asia/Shanghai' do |tz|
- tz.offset :o0, 29152, 0, :LMT
- tz.offset :o1, 28800, 0, :CST
- tz.offset :o2, 28800, 3600, :CDT
-
- tz.transition 1927, 12, :o1, 6548164639, 2700
- tz.transition 1940, 6, :o2, 14578699, 6
- tz.transition 1940, 9, :o1, 19439225, 8
- tz.transition 1941, 3, :o2, 14580415, 6
- tz.transition 1941, 9, :o1, 19442145, 8
- tz.transition 1986, 5, :o2, 515520000
- tz.transition 1986, 9, :o1, 527007600
- tz.transition 1987, 4, :o2, 545155200
- tz.transition 1987, 9, :o1, 558457200
- tz.transition 1988, 4, :o2, 576604800
- tz.transition 1988, 9, :o1, 589906800
- tz.transition 1989, 4, :o2, 608659200
- tz.transition 1989, 9, :o1, 621961200
- tz.transition 1990, 4, :o2, 640108800
- tz.transition 1990, 9, :o1, 653410800
- tz.transition 1991, 4, :o2, 671558400
- tz.transition 1991, 9, :o1, 684860400
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Singapore.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Singapore.rb
deleted file mode 100644
index b323a78f74..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Singapore.rb
+++ /dev/null
@@ -1,33 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Singapore
- include TimezoneDefinition
-
- timezone 'Asia/Singapore' do |tz|
- tz.offset :o0, 24925, 0, :LMT
- tz.offset :o1, 24925, 0, :SMT
- tz.offset :o2, 25200, 0, :MALT
- tz.offset :o3, 25200, 1200, :MALST
- tz.offset :o4, 26400, 0, :MALT
- tz.offset :o5, 27000, 0, :MALT
- tz.offset :o6, 32400, 0, :JST
- tz.offset :o7, 27000, 0, :SGT
- tz.offset :o8, 28800, 0, :SGT
-
- tz.transition 1900, 12, :o1, 8347571291, 3456
- tz.transition 1905, 5, :o2, 8353142363, 3456
- tz.transition 1932, 12, :o3, 58249757, 24
- tz.transition 1935, 12, :o4, 87414055, 36
- tz.transition 1941, 8, :o5, 87488575, 36
- tz.transition 1942, 2, :o6, 38886499, 16
- tz.transition 1945, 9, :o5, 19453681, 8
- tz.transition 1965, 8, :o7, 39023699, 16
- tz.transition 1981, 12, :o8, 378664200
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Taipei.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Taipei.rb
deleted file mode 100644
index 3ba12108fb..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Taipei.rb
+++ /dev/null
@@ -1,59 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Taipei
- include TimezoneDefinition
-
- timezone 'Asia/Taipei' do |tz|
- tz.offset :o0, 29160, 0, :LMT
- tz.offset :o1, 28800, 0, :CST
- tz.offset :o2, 28800, 3600, :CDT
-
- tz.transition 1895, 12, :o1, 193084733, 80
- tz.transition 1945, 4, :o2, 14589457, 6
- tz.transition 1945, 9, :o1, 19453833, 8
- tz.transition 1946, 4, :o2, 14591647, 6
- tz.transition 1946, 9, :o1, 19456753, 8
- tz.transition 1947, 4, :o2, 14593837, 6
- tz.transition 1947, 9, :o1, 19459673, 8
- tz.transition 1948, 4, :o2, 14596033, 6
- tz.transition 1948, 9, :o1, 19462601, 8
- tz.transition 1949, 4, :o2, 14598223, 6
- tz.transition 1949, 9, :o1, 19465521, 8
- tz.transition 1950, 4, :o2, 14600413, 6
- tz.transition 1950, 9, :o1, 19468441, 8
- tz.transition 1951, 4, :o2, 14602603, 6
- tz.transition 1951, 9, :o1, 19471361, 8
- tz.transition 1952, 2, :o2, 14604433, 6
- tz.transition 1952, 10, :o1, 19474537, 8
- tz.transition 1953, 3, :o2, 14606809, 6
- tz.transition 1953, 10, :o1, 19477457, 8
- tz.transition 1954, 3, :o2, 14608999, 6
- tz.transition 1954, 10, :o1, 19480377, 8
- tz.transition 1955, 3, :o2, 14611189, 6
- tz.transition 1955, 9, :o1, 19483049, 8
- tz.transition 1956, 3, :o2, 14613385, 6
- tz.transition 1956, 9, :o1, 19485977, 8
- tz.transition 1957, 3, :o2, 14615575, 6
- tz.transition 1957, 9, :o1, 19488897, 8
- tz.transition 1958, 3, :o2, 14617765, 6
- tz.transition 1958, 9, :o1, 19491817, 8
- tz.transition 1959, 3, :o2, 14619955, 6
- tz.transition 1959, 9, :o1, 19494737, 8
- tz.transition 1960, 5, :o2, 14622517, 6
- tz.transition 1960, 9, :o1, 19497665, 8
- tz.transition 1961, 5, :o2, 14624707, 6
- tz.transition 1961, 9, :o1, 19500585, 8
- tz.transition 1974, 3, :o2, 133977600
- tz.transition 1974, 9, :o1, 149785200
- tz.transition 1975, 3, :o2, 165513600
- tz.transition 1975, 9, :o1, 181321200
- tz.transition 1980, 6, :o2, 331142400
- tz.transition 1980, 9, :o1, 339087600
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Tashkent.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Tashkent.rb
deleted file mode 100644
index c205c7934d..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Tashkent.rb
+++ /dev/null
@@ -1,47 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Tashkent
- include TimezoneDefinition
-
- timezone 'Asia/Tashkent' do |tz|
- tz.offset :o0, 16632, 0, :LMT
- tz.offset :o1, 18000, 0, :TAST
- tz.offset :o2, 21600, 0, :TAST
- tz.offset :o3, 21600, 3600, :TASST
- tz.offset :o4, 18000, 3600, :TASST
- tz.offset :o5, 18000, 3600, :UZST
- tz.offset :o6, 18000, 0, :UZT
-
- tz.transition 1924, 5, :o1, 969562923, 400
- tz.transition 1930, 6, :o2, 58227559, 24
- tz.transition 1981, 3, :o3, 354909600
- tz.transition 1981, 9, :o2, 370717200
- tz.transition 1982, 3, :o3, 386445600
- tz.transition 1982, 9, :o2, 402253200
- tz.transition 1983, 3, :o3, 417981600
- tz.transition 1983, 9, :o2, 433789200
- tz.transition 1984, 3, :o3, 449604000
- tz.transition 1984, 9, :o2, 465336000
- tz.transition 1985, 3, :o3, 481060800
- tz.transition 1985, 9, :o2, 496785600
- tz.transition 1986, 3, :o3, 512510400
- tz.transition 1986, 9, :o2, 528235200
- tz.transition 1987, 3, :o3, 543960000
- tz.transition 1987, 9, :o2, 559684800
- tz.transition 1988, 3, :o3, 575409600
- tz.transition 1988, 9, :o2, 591134400
- tz.transition 1989, 3, :o3, 606859200
- tz.transition 1989, 9, :o2, 622584000
- tz.transition 1990, 3, :o3, 638308800
- tz.transition 1990, 9, :o2, 654638400
- tz.transition 1991, 3, :o4, 670363200
- tz.transition 1991, 8, :o5, 683661600
- tz.transition 1991, 9, :o6, 686091600
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Tbilisi.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Tbilisi.rb
deleted file mode 100644
index 15792a5651..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Tbilisi.rb
+++ /dev/null
@@ -1,78 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Tbilisi
- include TimezoneDefinition
-
- timezone 'Asia/Tbilisi' do |tz|
- tz.offset :o0, 10756, 0, :LMT
- tz.offset :o1, 10756, 0, :TBMT
- tz.offset :o2, 10800, 0, :TBIT
- tz.offset :o3, 14400, 0, :TBIT
- tz.offset :o4, 14400, 3600, :TBIST
- tz.offset :o5, 10800, 3600, :TBIST
- tz.offset :o6, 10800, 3600, :GEST
- tz.offset :o7, 10800, 0, :GET
- tz.offset :o8, 14400, 0, :GET
- tz.offset :o9, 14400, 3600, :GEST
-
- tz.transition 1879, 12, :o1, 52006652111, 21600
- tz.transition 1924, 5, :o2, 52356399311, 21600
- tz.transition 1957, 2, :o3, 19487187, 8
- tz.transition 1981, 3, :o4, 354916800
- tz.transition 1981, 9, :o3, 370724400
- tz.transition 1982, 3, :o4, 386452800
- tz.transition 1982, 9, :o3, 402260400
- tz.transition 1983, 3, :o4, 417988800
- tz.transition 1983, 9, :o3, 433796400
- tz.transition 1984, 3, :o4, 449611200
- tz.transition 1984, 9, :o3, 465343200
- tz.transition 1985, 3, :o4, 481068000
- tz.transition 1985, 9, :o3, 496792800
- tz.transition 1986, 3, :o4, 512517600
- tz.transition 1986, 9, :o3, 528242400
- tz.transition 1987, 3, :o4, 543967200
- tz.transition 1987, 9, :o3, 559692000
- tz.transition 1988, 3, :o4, 575416800
- tz.transition 1988, 9, :o3, 591141600
- tz.transition 1989, 3, :o4, 606866400
- tz.transition 1989, 9, :o3, 622591200
- tz.transition 1990, 3, :o4, 638316000
- tz.transition 1990, 9, :o3, 654645600
- tz.transition 1991, 3, :o5, 670370400
- tz.transition 1991, 4, :o6, 671140800
- tz.transition 1991, 9, :o7, 686098800
- tz.transition 1992, 3, :o6, 701816400
- tz.transition 1992, 9, :o7, 717537600
- tz.transition 1993, 3, :o6, 733266000
- tz.transition 1993, 9, :o7, 748987200
- tz.transition 1994, 3, :o6, 764715600
- tz.transition 1994, 9, :o8, 780436800
- tz.transition 1995, 3, :o9, 796161600
- tz.transition 1995, 9, :o8, 811882800
- tz.transition 1996, 3, :o9, 828216000
- tz.transition 1997, 3, :o9, 859662000
- tz.transition 1997, 10, :o8, 877806000
- tz.transition 1998, 3, :o9, 891115200
- tz.transition 1998, 10, :o8, 909255600
- tz.transition 1999, 3, :o9, 922564800
- tz.transition 1999, 10, :o8, 941310000
- tz.transition 2000, 3, :o9, 954014400
- tz.transition 2000, 10, :o8, 972759600
- tz.transition 2001, 3, :o9, 985464000
- tz.transition 2001, 10, :o8, 1004209200
- tz.transition 2002, 3, :o9, 1017518400
- tz.transition 2002, 10, :o8, 1035658800
- tz.transition 2003, 3, :o9, 1048968000
- tz.transition 2003, 10, :o8, 1067108400
- tz.transition 2004, 3, :o9, 1080417600
- tz.transition 2004, 6, :o6, 1088276400
- tz.transition 2004, 10, :o7, 1099177200
- tz.transition 2005, 3, :o8, 1111878000
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Tehran.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Tehran.rb
deleted file mode 100644
index d8df964a46..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Tehran.rb
+++ /dev/null
@@ -1,121 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Tehran
- include TimezoneDefinition
-
- timezone 'Asia/Tehran' do |tz|
- tz.offset :o0, 12344, 0, :LMT
- tz.offset :o1, 12344, 0, :TMT
- tz.offset :o2, 12600, 0, :IRST
- tz.offset :o3, 14400, 0, :IRST
- tz.offset :o4, 14400, 3600, :IRDT
- tz.offset :o5, 12600, 3600, :IRDT
-
- tz.transition 1915, 12, :o1, 26145324257, 10800
- tz.transition 1945, 12, :o2, 26263670657, 10800
- tz.transition 1977, 10, :o3, 247177800
- tz.transition 1978, 3, :o4, 259272000
- tz.transition 1978, 10, :o3, 277758000
- tz.transition 1978, 12, :o2, 283982400
- tz.transition 1979, 3, :o5, 290809800
- tz.transition 1979, 9, :o2, 306531000
- tz.transition 1980, 3, :o5, 322432200
- tz.transition 1980, 9, :o2, 338499000
- tz.transition 1991, 5, :o5, 673216200
- tz.transition 1991, 9, :o2, 685481400
- tz.transition 1992, 3, :o5, 701209800
- tz.transition 1992, 9, :o2, 717103800
- tz.transition 1993, 3, :o5, 732745800
- tz.transition 1993, 9, :o2, 748639800
- tz.transition 1994, 3, :o5, 764281800
- tz.transition 1994, 9, :o2, 780175800
- tz.transition 1995, 3, :o5, 795817800
- tz.transition 1995, 9, :o2, 811711800
- tz.transition 1996, 3, :o5, 827353800
- tz.transition 1996, 9, :o2, 843247800
- tz.transition 1997, 3, :o5, 858976200
- tz.transition 1997, 9, :o2, 874870200
- tz.transition 1998, 3, :o5, 890512200
- tz.transition 1998, 9, :o2, 906406200
- tz.transition 1999, 3, :o5, 922048200
- tz.transition 1999, 9, :o2, 937942200
- tz.transition 2000, 3, :o5, 953584200
- tz.transition 2000, 9, :o2, 969478200
- tz.transition 2001, 3, :o5, 985206600
- tz.transition 2001, 9, :o2, 1001100600
- tz.transition 2002, 3, :o5, 1016742600
- tz.transition 2002, 9, :o2, 1032636600
- tz.transition 2003, 3, :o5, 1048278600
- tz.transition 2003, 9, :o2, 1064172600
- tz.transition 2004, 3, :o5, 1079814600
- tz.transition 2004, 9, :o2, 1095708600
- tz.transition 2005, 3, :o5, 1111437000
- tz.transition 2005, 9, :o2, 1127331000
- tz.transition 2008, 3, :o5, 1206045000
- tz.transition 2008, 9, :o2, 1221939000
- tz.transition 2009, 3, :o5, 1237667400
- tz.transition 2009, 9, :o2, 1253561400
- tz.transition 2010, 3, :o5, 1269203400
- tz.transition 2010, 9, :o2, 1285097400
- tz.transition 2011, 3, :o5, 1300739400
- tz.transition 2011, 9, :o2, 1316633400
- tz.transition 2012, 3, :o5, 1332275400
- tz.transition 2012, 9, :o2, 1348169400
- tz.transition 2013, 3, :o5, 1363897800
- tz.transition 2013, 9, :o2, 1379791800
- tz.transition 2014, 3, :o5, 1395433800
- tz.transition 2014, 9, :o2, 1411327800
- tz.transition 2015, 3, :o5, 1426969800
- tz.transition 2015, 9, :o2, 1442863800
- tz.transition 2016, 3, :o5, 1458505800
- tz.transition 2016, 9, :o2, 1474399800
- tz.transition 2017, 3, :o5, 1490128200
- tz.transition 2017, 9, :o2, 1506022200
- tz.transition 2018, 3, :o5, 1521664200
- tz.transition 2018, 9, :o2, 1537558200
- tz.transition 2019, 3, :o5, 1553200200
- tz.transition 2019, 9, :o2, 1569094200
- tz.transition 2020, 3, :o5, 1584736200
- tz.transition 2020, 9, :o2, 1600630200
- tz.transition 2021, 3, :o5, 1616358600
- tz.transition 2021, 9, :o2, 1632252600
- tz.transition 2022, 3, :o5, 1647894600
- tz.transition 2022, 9, :o2, 1663788600
- tz.transition 2023, 3, :o5, 1679430600
- tz.transition 2023, 9, :o2, 1695324600
- tz.transition 2024, 3, :o5, 1710966600
- tz.transition 2024, 9, :o2, 1726860600
- tz.transition 2025, 3, :o5, 1742589000
- tz.transition 2025, 9, :o2, 1758483000
- tz.transition 2026, 3, :o5, 1774125000
- tz.transition 2026, 9, :o2, 1790019000
- tz.transition 2027, 3, :o5, 1805661000
- tz.transition 2027, 9, :o2, 1821555000
- tz.transition 2028, 3, :o5, 1837197000
- tz.transition 2028, 9, :o2, 1853091000
- tz.transition 2029, 3, :o5, 1868733000
- tz.transition 2029, 9, :o2, 1884627000
- tz.transition 2030, 3, :o5, 1900355400
- tz.transition 2030, 9, :o2, 1916249400
- tz.transition 2031, 3, :o5, 1931891400
- tz.transition 2031, 9, :o2, 1947785400
- tz.transition 2032, 3, :o5, 1963427400
- tz.transition 2032, 9, :o2, 1979321400
- tz.transition 2033, 3, :o5, 1994963400
- tz.transition 2033, 9, :o2, 2010857400
- tz.transition 2034, 3, :o5, 2026585800
- tz.transition 2034, 9, :o2, 2042479800
- tz.transition 2035, 3, :o5, 2058121800
- tz.transition 2035, 9, :o2, 2074015800
- tz.transition 2036, 3, :o5, 2089657800
- tz.transition 2036, 9, :o2, 2105551800
- tz.transition 2037, 3, :o5, 2121193800
- tz.transition 2037, 9, :o2, 2137087800
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Tokyo.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Tokyo.rb
deleted file mode 100644
index 51c9e16421..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Tokyo.rb
+++ /dev/null
@@ -1,30 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Tokyo
- include TimezoneDefinition
-
- timezone 'Asia/Tokyo' do |tz|
- tz.offset :o0, 33539, 0, :LMT
- tz.offset :o1, 32400, 0, :JST
- tz.offset :o2, 32400, 0, :CJT
- tz.offset :o3, 32400, 3600, :JDT
-
- tz.transition 1887, 12, :o1, 19285097, 8
- tz.transition 1895, 12, :o2, 19308473, 8
- tz.transition 1937, 12, :o1, 19431193, 8
- tz.transition 1948, 5, :o3, 58384157, 24
- tz.transition 1948, 9, :o1, 14596831, 6
- tz.transition 1949, 4, :o3, 58392221, 24
- tz.transition 1949, 9, :o1, 14599015, 6
- tz.transition 1950, 5, :o3, 58401797, 24
- tz.transition 1950, 9, :o1, 14601199, 6
- tz.transition 1951, 5, :o3, 58410533, 24
- tz.transition 1951, 9, :o1, 14603383, 6
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Ulaanbaatar.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Ulaanbaatar.rb
deleted file mode 100644
index 2854f5c5fd..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Ulaanbaatar.rb
+++ /dev/null
@@ -1,65 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Ulaanbaatar
- include TimezoneDefinition
-
- timezone 'Asia/Ulaanbaatar' do |tz|
- tz.offset :o0, 25652, 0, :LMT
- tz.offset :o1, 25200, 0, :ULAT
- tz.offset :o2, 28800, 0, :ULAT
- tz.offset :o3, 28800, 3600, :ULAST
-
- tz.transition 1905, 7, :o1, 52208457187, 21600
- tz.transition 1977, 12, :o2, 252435600
- tz.transition 1983, 3, :o3, 417974400
- tz.transition 1983, 9, :o2, 433782000
- tz.transition 1984, 3, :o3, 449596800
- tz.transition 1984, 9, :o2, 465318000
- tz.transition 1985, 3, :o3, 481046400
- tz.transition 1985, 9, :o2, 496767600
- tz.transition 1986, 3, :o3, 512496000
- tz.transition 1986, 9, :o2, 528217200
- tz.transition 1987, 3, :o3, 543945600
- tz.transition 1987, 9, :o2, 559666800
- tz.transition 1988, 3, :o3, 575395200
- tz.transition 1988, 9, :o2, 591116400
- tz.transition 1989, 3, :o3, 606844800
- tz.transition 1989, 9, :o2, 622566000
- tz.transition 1990, 3, :o3, 638294400
- tz.transition 1990, 9, :o2, 654620400
- tz.transition 1991, 3, :o3, 670348800
- tz.transition 1991, 9, :o2, 686070000
- tz.transition 1992, 3, :o3, 701798400
- tz.transition 1992, 9, :o2, 717519600
- tz.transition 1993, 3, :o3, 733248000
- tz.transition 1993, 9, :o2, 748969200
- tz.transition 1994, 3, :o3, 764697600
- tz.transition 1994, 9, :o2, 780418800
- tz.transition 1995, 3, :o3, 796147200
- tz.transition 1995, 9, :o2, 811868400
- tz.transition 1996, 3, :o3, 828201600
- tz.transition 1996, 9, :o2, 843922800
- tz.transition 1997, 3, :o3, 859651200
- tz.transition 1997, 9, :o2, 875372400
- tz.transition 1998, 3, :o3, 891100800
- tz.transition 1998, 9, :o2, 906822000
- tz.transition 2001, 4, :o3, 988394400
- tz.transition 2001, 9, :o2, 1001696400
- tz.transition 2002, 3, :o3, 1017424800
- tz.transition 2002, 9, :o2, 1033146000
- tz.transition 2003, 3, :o3, 1048874400
- tz.transition 2003, 9, :o2, 1064595600
- tz.transition 2004, 3, :o3, 1080324000
- tz.transition 2004, 9, :o2, 1096045200
- tz.transition 2005, 3, :o3, 1111773600
- tz.transition 2005, 9, :o2, 1127494800
- tz.transition 2006, 3, :o3, 1143223200
- tz.transition 2006, 9, :o2, 1159549200
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Urumqi.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Urumqi.rb
deleted file mode 100644
index d793ff1341..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Urumqi.rb
+++ /dev/null
@@ -1,33 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Urumqi
- include TimezoneDefinition
-
- timezone 'Asia/Urumqi' do |tz|
- tz.offset :o0, 21020, 0, :LMT
- tz.offset :o1, 21600, 0, :URUT
- tz.offset :o2, 28800, 0, :CST
- tz.offset :o3, 28800, 3600, :CDT
-
- tz.transition 1927, 12, :o1, 10477063829, 4320
- tz.transition 1980, 4, :o2, 325965600
- tz.transition 1986, 5, :o3, 515520000
- tz.transition 1986, 9, :o2, 527007600
- tz.transition 1987, 4, :o3, 545155200
- tz.transition 1987, 9, :o2, 558457200
- tz.transition 1988, 4, :o3, 576604800
- tz.transition 1988, 9, :o2, 589906800
- tz.transition 1989, 4, :o3, 608659200
- tz.transition 1989, 9, :o2, 621961200
- tz.transition 1990, 4, :o3, 640108800
- tz.transition 1990, 9, :o2, 653410800
- tz.transition 1991, 4, :o3, 671558400
- tz.transition 1991, 9, :o2, 684860400
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Vladivostok.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Vladivostok.rb
deleted file mode 100644
index bd9e3d60ec..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Vladivostok.rb
+++ /dev/null
@@ -1,164 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Vladivostok
- include TimezoneDefinition
-
- timezone 'Asia/Vladivostok' do |tz|
- tz.offset :o0, 31664, 0, :LMT
- tz.offset :o1, 32400, 0, :VLAT
- tz.offset :o2, 36000, 0, :VLAT
- tz.offset :o3, 36000, 3600, :VLAST
- tz.offset :o4, 32400, 3600, :VLASST
- tz.offset :o5, 32400, 0, :VLAST
-
- tz.transition 1922, 11, :o1, 13086214921, 5400
- tz.transition 1930, 6, :o2, 19409185, 8
- tz.transition 1981, 3, :o3, 354895200
- tz.transition 1981, 9, :o2, 370702800
- tz.transition 1982, 3, :o3, 386431200
- tz.transition 1982, 9, :o2, 402238800
- tz.transition 1983, 3, :o3, 417967200
- tz.transition 1983, 9, :o2, 433774800
- tz.transition 1984, 3, :o3, 449589600
- tz.transition 1984, 9, :o2, 465321600
- tz.transition 1985, 3, :o3, 481046400
- tz.transition 1985, 9, :o2, 496771200
- tz.transition 1986, 3, :o3, 512496000
- tz.transition 1986, 9, :o2, 528220800
- tz.transition 1987, 3, :o3, 543945600
- tz.transition 1987, 9, :o2, 559670400
- tz.transition 1988, 3, :o3, 575395200
- tz.transition 1988, 9, :o2, 591120000
- tz.transition 1989, 3, :o3, 606844800
- tz.transition 1989, 9, :o2, 622569600
- tz.transition 1990, 3, :o3, 638294400
- tz.transition 1990, 9, :o2, 654624000
- tz.transition 1991, 3, :o4, 670348800
- tz.transition 1991, 9, :o5, 686077200
- tz.transition 1992, 1, :o2, 695754000
- tz.transition 1992, 3, :o3, 701787600
- tz.transition 1992, 9, :o2, 717508800
- tz.transition 1993, 3, :o3, 733248000
- tz.transition 1993, 9, :o2, 748972800
- tz.transition 1994, 3, :o3, 764697600
- tz.transition 1994, 9, :o2, 780422400
- tz.transition 1995, 3, :o3, 796147200
- tz.transition 1995, 9, :o2, 811872000
- tz.transition 1996, 3, :o3, 828201600
- tz.transition 1996, 10, :o2, 846345600
- tz.transition 1997, 3, :o3, 859651200
- tz.transition 1997, 10, :o2, 877795200
- tz.transition 1998, 3, :o3, 891100800
- tz.transition 1998, 10, :o2, 909244800
- tz.transition 1999, 3, :o3, 922550400
- tz.transition 1999, 10, :o2, 941299200
- tz.transition 2000, 3, :o3, 954000000
- tz.transition 2000, 10, :o2, 972748800
- tz.transition 2001, 3, :o3, 985449600
- tz.transition 2001, 10, :o2, 1004198400
- tz.transition 2002, 3, :o3, 1017504000
- tz.transition 2002, 10, :o2, 1035648000
- tz.transition 2003, 3, :o3, 1048953600
- tz.transition 2003, 10, :o2, 1067097600
- tz.transition 2004, 3, :o3, 1080403200
- tz.transition 2004, 10, :o2, 1099152000
- tz.transition 2005, 3, :o3, 1111852800
- tz.transition 2005, 10, :o2, 1130601600
- tz.transition 2006, 3, :o3, 1143302400
- tz.transition 2006, 10, :o2, 1162051200
- tz.transition 2007, 3, :o3, 1174752000
- tz.transition 2007, 10, :o2, 1193500800
- tz.transition 2008, 3, :o3, 1206806400
- tz.transition 2008, 10, :o2, 1224950400
- tz.transition 2009, 3, :o3, 1238256000
- tz.transition 2009, 10, :o2, 1256400000
- tz.transition 2010, 3, :o3, 1269705600
- tz.transition 2010, 10, :o2, 1288454400
- tz.transition 2011, 3, :o3, 1301155200
- tz.transition 2011, 10, :o2, 1319904000
- tz.transition 2012, 3, :o3, 1332604800
- tz.transition 2012, 10, :o2, 1351353600
- tz.transition 2013, 3, :o3, 1364659200
- tz.transition 2013, 10, :o2, 1382803200
- tz.transition 2014, 3, :o3, 1396108800
- tz.transition 2014, 10, :o2, 1414252800
- tz.transition 2015, 3, :o3, 1427558400
- tz.transition 2015, 10, :o2, 1445702400
- tz.transition 2016, 3, :o3, 1459008000
- tz.transition 2016, 10, :o2, 1477756800
- tz.transition 2017, 3, :o3, 1490457600
- tz.transition 2017, 10, :o2, 1509206400
- tz.transition 2018, 3, :o3, 1521907200
- tz.transition 2018, 10, :o2, 1540656000
- tz.transition 2019, 3, :o3, 1553961600
- tz.transition 2019, 10, :o2, 1572105600
- tz.transition 2020, 3, :o3, 1585411200
- tz.transition 2020, 10, :o2, 1603555200
- tz.transition 2021, 3, :o3, 1616860800
- tz.transition 2021, 10, :o2, 1635609600
- tz.transition 2022, 3, :o3, 1648310400
- tz.transition 2022, 10, :o2, 1667059200
- tz.transition 2023, 3, :o3, 1679760000
- tz.transition 2023, 10, :o2, 1698508800
- tz.transition 2024, 3, :o3, 1711814400
- tz.transition 2024, 10, :o2, 1729958400
- tz.transition 2025, 3, :o3, 1743264000
- tz.transition 2025, 10, :o2, 1761408000
- tz.transition 2026, 3, :o3, 1774713600
- tz.transition 2026, 10, :o2, 1792857600
- tz.transition 2027, 3, :o3, 1806163200
- tz.transition 2027, 10, :o2, 1824912000
- tz.transition 2028, 3, :o3, 1837612800
- tz.transition 2028, 10, :o2, 1856361600
- tz.transition 2029, 3, :o3, 1869062400
- tz.transition 2029, 10, :o2, 1887811200
- tz.transition 2030, 3, :o3, 1901116800
- tz.transition 2030, 10, :o2, 1919260800
- tz.transition 2031, 3, :o3, 1932566400
- tz.transition 2031, 10, :o2, 1950710400
- tz.transition 2032, 3, :o3, 1964016000
- tz.transition 2032, 10, :o2, 1982764800
- tz.transition 2033, 3, :o3, 1995465600
- tz.transition 2033, 10, :o2, 2014214400
- tz.transition 2034, 3, :o3, 2026915200
- tz.transition 2034, 10, :o2, 2045664000
- tz.transition 2035, 3, :o3, 2058364800
- tz.transition 2035, 10, :o2, 2077113600
- tz.transition 2036, 3, :o3, 2090419200
- tz.transition 2036, 10, :o2, 2108563200
- tz.transition 2037, 3, :o3, 2121868800
- tz.transition 2037, 10, :o2, 2140012800
- tz.transition 2038, 3, :o3, 14793061, 6
- tz.transition 2038, 10, :o2, 14794363, 6
- tz.transition 2039, 3, :o3, 14795245, 6
- tz.transition 2039, 10, :o2, 14796547, 6
- tz.transition 2040, 3, :o3, 14797429, 6
- tz.transition 2040, 10, :o2, 14798731, 6
- tz.transition 2041, 3, :o3, 14799655, 6
- tz.transition 2041, 10, :o2, 14800915, 6
- tz.transition 2042, 3, :o3, 14801839, 6
- tz.transition 2042, 10, :o2, 14803099, 6
- tz.transition 2043, 3, :o3, 14804023, 6
- tz.transition 2043, 10, :o2, 14805283, 6
- tz.transition 2044, 3, :o3, 14806207, 6
- tz.transition 2044, 10, :o2, 14807509, 6
- tz.transition 2045, 3, :o3, 14808391, 6
- tz.transition 2045, 10, :o2, 14809693, 6
- tz.transition 2046, 3, :o3, 14810575, 6
- tz.transition 2046, 10, :o2, 14811877, 6
- tz.transition 2047, 3, :o3, 14812801, 6
- tz.transition 2047, 10, :o2, 14814061, 6
- tz.transition 2048, 3, :o3, 14814985, 6
- tz.transition 2048, 10, :o2, 14816245, 6
- tz.transition 2049, 3, :o3, 14817169, 6
- tz.transition 2049, 10, :o2, 14818471, 6
- tz.transition 2050, 3, :o3, 14819353, 6
- tz.transition 2050, 10, :o2, 14820655, 6
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Yakutsk.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Yakutsk.rb
deleted file mode 100644
index 56435a788f..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Yakutsk.rb
+++ /dev/null
@@ -1,163 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Yakutsk
- include TimezoneDefinition
-
- timezone 'Asia/Yakutsk' do |tz|
- tz.offset :o0, 31120, 0, :LMT
- tz.offset :o1, 28800, 0, :YAKT
- tz.offset :o2, 32400, 0, :YAKT
- tz.offset :o3, 32400, 3600, :YAKST
- tz.offset :o4, 28800, 3600, :YAKST
-
- tz.transition 1919, 12, :o1, 2616091711, 1080
- tz.transition 1930, 6, :o2, 14556889, 6
- tz.transition 1981, 3, :o3, 354898800
- tz.transition 1981, 9, :o2, 370706400
- tz.transition 1982, 3, :o3, 386434800
- tz.transition 1982, 9, :o2, 402242400
- tz.transition 1983, 3, :o3, 417970800
- tz.transition 1983, 9, :o2, 433778400
- tz.transition 1984, 3, :o3, 449593200
- tz.transition 1984, 9, :o2, 465325200
- tz.transition 1985, 3, :o3, 481050000
- tz.transition 1985, 9, :o2, 496774800
- tz.transition 1986, 3, :o3, 512499600
- tz.transition 1986, 9, :o2, 528224400
- tz.transition 1987, 3, :o3, 543949200
- tz.transition 1987, 9, :o2, 559674000
- tz.transition 1988, 3, :o3, 575398800
- tz.transition 1988, 9, :o2, 591123600
- tz.transition 1989, 3, :o3, 606848400
- tz.transition 1989, 9, :o2, 622573200
- tz.transition 1990, 3, :o3, 638298000
- tz.transition 1990, 9, :o2, 654627600
- tz.transition 1991, 3, :o4, 670352400
- tz.transition 1991, 9, :o1, 686080800
- tz.transition 1992, 1, :o2, 695757600
- tz.transition 1992, 3, :o3, 701791200
- tz.transition 1992, 9, :o2, 717512400
- tz.transition 1993, 3, :o3, 733251600
- tz.transition 1993, 9, :o2, 748976400
- tz.transition 1994, 3, :o3, 764701200
- tz.transition 1994, 9, :o2, 780426000
- tz.transition 1995, 3, :o3, 796150800
- tz.transition 1995, 9, :o2, 811875600
- tz.transition 1996, 3, :o3, 828205200
- tz.transition 1996, 10, :o2, 846349200
- tz.transition 1997, 3, :o3, 859654800
- tz.transition 1997, 10, :o2, 877798800
- tz.transition 1998, 3, :o3, 891104400
- tz.transition 1998, 10, :o2, 909248400
- tz.transition 1999, 3, :o3, 922554000
- tz.transition 1999, 10, :o2, 941302800
- tz.transition 2000, 3, :o3, 954003600
- tz.transition 2000, 10, :o2, 972752400
- tz.transition 2001, 3, :o3, 985453200
- tz.transition 2001, 10, :o2, 1004202000
- tz.transition 2002, 3, :o3, 1017507600
- tz.transition 2002, 10, :o2, 1035651600
- tz.transition 2003, 3, :o3, 1048957200
- tz.transition 2003, 10, :o2, 1067101200
- tz.transition 2004, 3, :o3, 1080406800
- tz.transition 2004, 10, :o2, 1099155600
- tz.transition 2005, 3, :o3, 1111856400
- tz.transition 2005, 10, :o2, 1130605200
- tz.transition 2006, 3, :o3, 1143306000
- tz.transition 2006, 10, :o2, 1162054800
- tz.transition 2007, 3, :o3, 1174755600
- tz.transition 2007, 10, :o2, 1193504400
- tz.transition 2008, 3, :o3, 1206810000
- tz.transition 2008, 10, :o2, 1224954000
- tz.transition 2009, 3, :o3, 1238259600
- tz.transition 2009, 10, :o2, 1256403600
- tz.transition 2010, 3, :o3, 1269709200
- tz.transition 2010, 10, :o2, 1288458000
- tz.transition 2011, 3, :o3, 1301158800
- tz.transition 2011, 10, :o2, 1319907600
- tz.transition 2012, 3, :o3, 1332608400
- tz.transition 2012, 10, :o2, 1351357200
- tz.transition 2013, 3, :o3, 1364662800
- tz.transition 2013, 10, :o2, 1382806800
- tz.transition 2014, 3, :o3, 1396112400
- tz.transition 2014, 10, :o2, 1414256400
- tz.transition 2015, 3, :o3, 1427562000
- tz.transition 2015, 10, :o2, 1445706000
- tz.transition 2016, 3, :o3, 1459011600
- tz.transition 2016, 10, :o2, 1477760400
- tz.transition 2017, 3, :o3, 1490461200
- tz.transition 2017, 10, :o2, 1509210000
- tz.transition 2018, 3, :o3, 1521910800
- tz.transition 2018, 10, :o2, 1540659600
- tz.transition 2019, 3, :o3, 1553965200
- tz.transition 2019, 10, :o2, 1572109200
- tz.transition 2020, 3, :o3, 1585414800
- tz.transition 2020, 10, :o2, 1603558800
- tz.transition 2021, 3, :o3, 1616864400
- tz.transition 2021, 10, :o2, 1635613200
- tz.transition 2022, 3, :o3, 1648314000
- tz.transition 2022, 10, :o2, 1667062800
- tz.transition 2023, 3, :o3, 1679763600
- tz.transition 2023, 10, :o2, 1698512400
- tz.transition 2024, 3, :o3, 1711818000
- tz.transition 2024, 10, :o2, 1729962000
- tz.transition 2025, 3, :o3, 1743267600
- tz.transition 2025, 10, :o2, 1761411600
- tz.transition 2026, 3, :o3, 1774717200
- tz.transition 2026, 10, :o2, 1792861200
- tz.transition 2027, 3, :o3, 1806166800
- tz.transition 2027, 10, :o2, 1824915600
- tz.transition 2028, 3, :o3, 1837616400
- tz.transition 2028, 10, :o2, 1856365200
- tz.transition 2029, 3, :o3, 1869066000
- tz.transition 2029, 10, :o2, 1887814800
- tz.transition 2030, 3, :o3, 1901120400
- tz.transition 2030, 10, :o2, 1919264400
- tz.transition 2031, 3, :o3, 1932570000
- tz.transition 2031, 10, :o2, 1950714000
- tz.transition 2032, 3, :o3, 1964019600
- tz.transition 2032, 10, :o2, 1982768400
- tz.transition 2033, 3, :o3, 1995469200
- tz.transition 2033, 10, :o2, 2014218000
- tz.transition 2034, 3, :o3, 2026918800
- tz.transition 2034, 10, :o2, 2045667600
- tz.transition 2035, 3, :o3, 2058368400
- tz.transition 2035, 10, :o2, 2077117200
- tz.transition 2036, 3, :o3, 2090422800
- tz.transition 2036, 10, :o2, 2108566800
- tz.transition 2037, 3, :o3, 2121872400
- tz.transition 2037, 10, :o2, 2140016400
- tz.transition 2038, 3, :o3, 59172245, 24
- tz.transition 2038, 10, :o2, 59177453, 24
- tz.transition 2039, 3, :o3, 59180981, 24
- tz.transition 2039, 10, :o2, 59186189, 24
- tz.transition 2040, 3, :o3, 59189717, 24
- tz.transition 2040, 10, :o2, 59194925, 24
- tz.transition 2041, 3, :o3, 59198621, 24
- tz.transition 2041, 10, :o2, 59203661, 24
- tz.transition 2042, 3, :o3, 59207357, 24
- tz.transition 2042, 10, :o2, 59212397, 24
- tz.transition 2043, 3, :o3, 59216093, 24
- tz.transition 2043, 10, :o2, 59221133, 24
- tz.transition 2044, 3, :o3, 59224829, 24
- tz.transition 2044, 10, :o2, 59230037, 24
- tz.transition 2045, 3, :o3, 59233565, 24
- tz.transition 2045, 10, :o2, 59238773, 24
- tz.transition 2046, 3, :o3, 59242301, 24
- tz.transition 2046, 10, :o2, 59247509, 24
- tz.transition 2047, 3, :o3, 59251205, 24
- tz.transition 2047, 10, :o2, 59256245, 24
- tz.transition 2048, 3, :o3, 59259941, 24
- tz.transition 2048, 10, :o2, 59264981, 24
- tz.transition 2049, 3, :o3, 59268677, 24
- tz.transition 2049, 10, :o2, 59273885, 24
- tz.transition 2050, 3, :o3, 59277413, 24
- tz.transition 2050, 10, :o2, 59282621, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Yekaterinburg.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Yekaterinburg.rb
deleted file mode 100644
index 8ef8df4a41..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Yekaterinburg.rb
+++ /dev/null
@@ -1,165 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Yekaterinburg
- include TimezoneDefinition
-
- timezone 'Asia/Yekaterinburg' do |tz|
- tz.offset :o0, 14544, 0, :LMT
- tz.offset :o1, 14400, 0, :SVET
- tz.offset :o2, 18000, 0, :SVET
- tz.offset :o3, 18000, 3600, :SVEST
- tz.offset :o4, 14400, 3600, :SVEST
- tz.offset :o5, 18000, 0, :YEKT
- tz.offset :o6, 18000, 3600, :YEKST
-
- tz.transition 1919, 7, :o1, 1453292699, 600
- tz.transition 1930, 6, :o2, 7278445, 3
- tz.transition 1981, 3, :o3, 354913200
- tz.transition 1981, 9, :o2, 370720800
- tz.transition 1982, 3, :o3, 386449200
- tz.transition 1982, 9, :o2, 402256800
- tz.transition 1983, 3, :o3, 417985200
- tz.transition 1983, 9, :o2, 433792800
- tz.transition 1984, 3, :o3, 449607600
- tz.transition 1984, 9, :o2, 465339600
- tz.transition 1985, 3, :o3, 481064400
- tz.transition 1985, 9, :o2, 496789200
- tz.transition 1986, 3, :o3, 512514000
- tz.transition 1986, 9, :o2, 528238800
- tz.transition 1987, 3, :o3, 543963600
- tz.transition 1987, 9, :o2, 559688400
- tz.transition 1988, 3, :o3, 575413200
- tz.transition 1988, 9, :o2, 591138000
- tz.transition 1989, 3, :o3, 606862800
- tz.transition 1989, 9, :o2, 622587600
- tz.transition 1990, 3, :o3, 638312400
- tz.transition 1990, 9, :o2, 654642000
- tz.transition 1991, 3, :o4, 670366800
- tz.transition 1991, 9, :o1, 686095200
- tz.transition 1992, 1, :o5, 695772000
- tz.transition 1992, 3, :o6, 701805600
- tz.transition 1992, 9, :o5, 717526800
- tz.transition 1993, 3, :o6, 733266000
- tz.transition 1993, 9, :o5, 748990800
- tz.transition 1994, 3, :o6, 764715600
- tz.transition 1994, 9, :o5, 780440400
- tz.transition 1995, 3, :o6, 796165200
- tz.transition 1995, 9, :o5, 811890000
- tz.transition 1996, 3, :o6, 828219600
- tz.transition 1996, 10, :o5, 846363600
- tz.transition 1997, 3, :o6, 859669200
- tz.transition 1997, 10, :o5, 877813200
- tz.transition 1998, 3, :o6, 891118800
- tz.transition 1998, 10, :o5, 909262800
- tz.transition 1999, 3, :o6, 922568400
- tz.transition 1999, 10, :o5, 941317200
- tz.transition 2000, 3, :o6, 954018000
- tz.transition 2000, 10, :o5, 972766800
- tz.transition 2001, 3, :o6, 985467600
- tz.transition 2001, 10, :o5, 1004216400
- tz.transition 2002, 3, :o6, 1017522000
- tz.transition 2002, 10, :o5, 1035666000
- tz.transition 2003, 3, :o6, 1048971600
- tz.transition 2003, 10, :o5, 1067115600
- tz.transition 2004, 3, :o6, 1080421200
- tz.transition 2004, 10, :o5, 1099170000
- tz.transition 2005, 3, :o6, 1111870800
- tz.transition 2005, 10, :o5, 1130619600
- tz.transition 2006, 3, :o6, 1143320400
- tz.transition 2006, 10, :o5, 1162069200
- tz.transition 2007, 3, :o6, 1174770000
- tz.transition 2007, 10, :o5, 1193518800
- tz.transition 2008, 3, :o6, 1206824400
- tz.transition 2008, 10, :o5, 1224968400
- tz.transition 2009, 3, :o6, 1238274000
- tz.transition 2009, 10, :o5, 1256418000
- tz.transition 2010, 3, :o6, 1269723600
- tz.transition 2010, 10, :o5, 1288472400
- tz.transition 2011, 3, :o6, 1301173200
- tz.transition 2011, 10, :o5, 1319922000
- tz.transition 2012, 3, :o6, 1332622800
- tz.transition 2012, 10, :o5, 1351371600
- tz.transition 2013, 3, :o6, 1364677200
- tz.transition 2013, 10, :o5, 1382821200
- tz.transition 2014, 3, :o6, 1396126800
- tz.transition 2014, 10, :o5, 1414270800
- tz.transition 2015, 3, :o6, 1427576400
- tz.transition 2015, 10, :o5, 1445720400
- tz.transition 2016, 3, :o6, 1459026000
- tz.transition 2016, 10, :o5, 1477774800
- tz.transition 2017, 3, :o6, 1490475600
- tz.transition 2017, 10, :o5, 1509224400
- tz.transition 2018, 3, :o6, 1521925200
- tz.transition 2018, 10, :o5, 1540674000
- tz.transition 2019, 3, :o6, 1553979600
- tz.transition 2019, 10, :o5, 1572123600
- tz.transition 2020, 3, :o6, 1585429200
- tz.transition 2020, 10, :o5, 1603573200
- tz.transition 2021, 3, :o6, 1616878800
- tz.transition 2021, 10, :o5, 1635627600
- tz.transition 2022, 3, :o6, 1648328400
- tz.transition 2022, 10, :o5, 1667077200
- tz.transition 2023, 3, :o6, 1679778000
- tz.transition 2023, 10, :o5, 1698526800
- tz.transition 2024, 3, :o6, 1711832400
- tz.transition 2024, 10, :o5, 1729976400
- tz.transition 2025, 3, :o6, 1743282000
- tz.transition 2025, 10, :o5, 1761426000
- tz.transition 2026, 3, :o6, 1774731600
- tz.transition 2026, 10, :o5, 1792875600
- tz.transition 2027, 3, :o6, 1806181200
- tz.transition 2027, 10, :o5, 1824930000
- tz.transition 2028, 3, :o6, 1837630800
- tz.transition 2028, 10, :o5, 1856379600
- tz.transition 2029, 3, :o6, 1869080400
- tz.transition 2029, 10, :o5, 1887829200
- tz.transition 2030, 3, :o6, 1901134800
- tz.transition 2030, 10, :o5, 1919278800
- tz.transition 2031, 3, :o6, 1932584400
- tz.transition 2031, 10, :o5, 1950728400
- tz.transition 2032, 3, :o6, 1964034000
- tz.transition 2032, 10, :o5, 1982782800
- tz.transition 2033, 3, :o6, 1995483600
- tz.transition 2033, 10, :o5, 2014232400
- tz.transition 2034, 3, :o6, 2026933200
- tz.transition 2034, 10, :o5, 2045682000
- tz.transition 2035, 3, :o6, 2058382800
- tz.transition 2035, 10, :o5, 2077131600
- tz.transition 2036, 3, :o6, 2090437200
- tz.transition 2036, 10, :o5, 2108581200
- tz.transition 2037, 3, :o6, 2121886800
- tz.transition 2037, 10, :o5, 2140030800
- tz.transition 2038, 3, :o6, 19724083, 8
- tz.transition 2038, 10, :o5, 19725819, 8
- tz.transition 2039, 3, :o6, 19726995, 8
- tz.transition 2039, 10, :o5, 19728731, 8
- tz.transition 2040, 3, :o6, 19729907, 8
- tz.transition 2040, 10, :o5, 19731643, 8
- tz.transition 2041, 3, :o6, 19732875, 8
- tz.transition 2041, 10, :o5, 19734555, 8
- tz.transition 2042, 3, :o6, 19735787, 8
- tz.transition 2042, 10, :o5, 19737467, 8
- tz.transition 2043, 3, :o6, 19738699, 8
- tz.transition 2043, 10, :o5, 19740379, 8
- tz.transition 2044, 3, :o6, 19741611, 8
- tz.transition 2044, 10, :o5, 19743347, 8
- tz.transition 2045, 3, :o6, 19744523, 8
- tz.transition 2045, 10, :o5, 19746259, 8
- tz.transition 2046, 3, :o6, 19747435, 8
- tz.transition 2046, 10, :o5, 19749171, 8
- tz.transition 2047, 3, :o6, 19750403, 8
- tz.transition 2047, 10, :o5, 19752083, 8
- tz.transition 2048, 3, :o6, 19753315, 8
- tz.transition 2048, 10, :o5, 19754995, 8
- tz.transition 2049, 3, :o6, 19756227, 8
- tz.transition 2049, 10, :o5, 19757963, 8
- tz.transition 2050, 3, :o6, 19759139, 8
- tz.transition 2050, 10, :o5, 19760875, 8
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Yerevan.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Yerevan.rb
deleted file mode 100644
index e7f160861f..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Asia/Yerevan.rb
+++ /dev/null
@@ -1,165 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Asia
- module Yerevan
- include TimezoneDefinition
-
- timezone 'Asia/Yerevan' do |tz|
- tz.offset :o0, 10680, 0, :LMT
- tz.offset :o1, 10800, 0, :YERT
- tz.offset :o2, 14400, 0, :YERT
- tz.offset :o3, 14400, 3600, :YERST
- tz.offset :o4, 10800, 3600, :YERST
- tz.offset :o5, 10800, 3600, :AMST
- tz.offset :o6, 10800, 0, :AMT
- tz.offset :o7, 14400, 0, :AMT
- tz.offset :o8, 14400, 3600, :AMST
-
- tz.transition 1924, 5, :o1, 1745213311, 720
- tz.transition 1957, 2, :o2, 19487187, 8
- tz.transition 1981, 3, :o3, 354916800
- tz.transition 1981, 9, :o2, 370724400
- tz.transition 1982, 3, :o3, 386452800
- tz.transition 1982, 9, :o2, 402260400
- tz.transition 1983, 3, :o3, 417988800
- tz.transition 1983, 9, :o2, 433796400
- tz.transition 1984, 3, :o3, 449611200
- tz.transition 1984, 9, :o2, 465343200
- tz.transition 1985, 3, :o3, 481068000
- tz.transition 1985, 9, :o2, 496792800
- tz.transition 1986, 3, :o3, 512517600
- tz.transition 1986, 9, :o2, 528242400
- tz.transition 1987, 3, :o3, 543967200
- tz.transition 1987, 9, :o2, 559692000
- tz.transition 1988, 3, :o3, 575416800
- tz.transition 1988, 9, :o2, 591141600
- tz.transition 1989, 3, :o3, 606866400
- tz.transition 1989, 9, :o2, 622591200
- tz.transition 1990, 3, :o3, 638316000
- tz.transition 1990, 9, :o2, 654645600
- tz.transition 1991, 3, :o4, 670370400
- tz.transition 1991, 9, :o5, 685569600
- tz.transition 1991, 9, :o6, 686098800
- tz.transition 1992, 3, :o5, 701812800
- tz.transition 1992, 9, :o6, 717534000
- tz.transition 1993, 3, :o5, 733273200
- tz.transition 1993, 9, :o6, 748998000
- tz.transition 1994, 3, :o5, 764722800
- tz.transition 1994, 9, :o6, 780447600
- tz.transition 1995, 3, :o5, 796172400
- tz.transition 1995, 9, :o7, 811897200
- tz.transition 1997, 3, :o8, 859672800
- tz.transition 1997, 10, :o7, 877816800
- tz.transition 1998, 3, :o8, 891122400
- tz.transition 1998, 10, :o7, 909266400
- tz.transition 1999, 3, :o8, 922572000
- tz.transition 1999, 10, :o7, 941320800
- tz.transition 2000, 3, :o8, 954021600
- tz.transition 2000, 10, :o7, 972770400
- tz.transition 2001, 3, :o8, 985471200
- tz.transition 2001, 10, :o7, 1004220000
- tz.transition 2002, 3, :o8, 1017525600
- tz.transition 2002, 10, :o7, 1035669600
- tz.transition 2003, 3, :o8, 1048975200
- tz.transition 2003, 10, :o7, 1067119200
- tz.transition 2004, 3, :o8, 1080424800
- tz.transition 2004, 10, :o7, 1099173600
- tz.transition 2005, 3, :o8, 1111874400
- tz.transition 2005, 10, :o7, 1130623200
- tz.transition 2006, 3, :o8, 1143324000
- tz.transition 2006, 10, :o7, 1162072800
- tz.transition 2007, 3, :o8, 1174773600
- tz.transition 2007, 10, :o7, 1193522400
- tz.transition 2008, 3, :o8, 1206828000
- tz.transition 2008, 10, :o7, 1224972000
- tz.transition 2009, 3, :o8, 1238277600
- tz.transition 2009, 10, :o7, 1256421600
- tz.transition 2010, 3, :o8, 1269727200
- tz.transition 2010, 10, :o7, 1288476000
- tz.transition 2011, 3, :o8, 1301176800
- tz.transition 2011, 10, :o7, 1319925600
- tz.transition 2012, 3, :o8, 1332626400
- tz.transition 2012, 10, :o7, 1351375200
- tz.transition 2013, 3, :o8, 1364680800
- tz.transition 2013, 10, :o7, 1382824800
- tz.transition 2014, 3, :o8, 1396130400
- tz.transition 2014, 10, :o7, 1414274400
- tz.transition 2015, 3, :o8, 1427580000
- tz.transition 2015, 10, :o7, 1445724000
- tz.transition 2016, 3, :o8, 1459029600
- tz.transition 2016, 10, :o7, 1477778400
- tz.transition 2017, 3, :o8, 1490479200
- tz.transition 2017, 10, :o7, 1509228000
- tz.transition 2018, 3, :o8, 1521928800
- tz.transition 2018, 10, :o7, 1540677600
- tz.transition 2019, 3, :o8, 1553983200
- tz.transition 2019, 10, :o7, 1572127200
- tz.transition 2020, 3, :o8, 1585432800
- tz.transition 2020, 10, :o7, 1603576800
- tz.transition 2021, 3, :o8, 1616882400
- tz.transition 2021, 10, :o7, 1635631200
- tz.transition 2022, 3, :o8, 1648332000
- tz.transition 2022, 10, :o7, 1667080800
- tz.transition 2023, 3, :o8, 1679781600
- tz.transition 2023, 10, :o7, 1698530400
- tz.transition 2024, 3, :o8, 1711836000
- tz.transition 2024, 10, :o7, 1729980000
- tz.transition 2025, 3, :o8, 1743285600
- tz.transition 2025, 10, :o7, 1761429600
- tz.transition 2026, 3, :o8, 1774735200
- tz.transition 2026, 10, :o7, 1792879200
- tz.transition 2027, 3, :o8, 1806184800
- tz.transition 2027, 10, :o7, 1824933600
- tz.transition 2028, 3, :o8, 1837634400
- tz.transition 2028, 10, :o7, 1856383200
- tz.transition 2029, 3, :o8, 1869084000
- tz.transition 2029, 10, :o7, 1887832800
- tz.transition 2030, 3, :o8, 1901138400
- tz.transition 2030, 10, :o7, 1919282400
- tz.transition 2031, 3, :o8, 1932588000
- tz.transition 2031, 10, :o7, 1950732000
- tz.transition 2032, 3, :o8, 1964037600
- tz.transition 2032, 10, :o7, 1982786400
- tz.transition 2033, 3, :o8, 1995487200
- tz.transition 2033, 10, :o7, 2014236000
- tz.transition 2034, 3, :o8, 2026936800
- tz.transition 2034, 10, :o7, 2045685600
- tz.transition 2035, 3, :o8, 2058386400
- tz.transition 2035, 10, :o7, 2077135200
- tz.transition 2036, 3, :o8, 2090440800
- tz.transition 2036, 10, :o7, 2108584800
- tz.transition 2037, 3, :o8, 2121890400
- tz.transition 2037, 10, :o7, 2140034400
- tz.transition 2038, 3, :o8, 29586125, 12
- tz.transition 2038, 10, :o7, 29588729, 12
- tz.transition 2039, 3, :o8, 29590493, 12
- tz.transition 2039, 10, :o7, 29593097, 12
- tz.transition 2040, 3, :o8, 29594861, 12
- tz.transition 2040, 10, :o7, 29597465, 12
- tz.transition 2041, 3, :o8, 29599313, 12
- tz.transition 2041, 10, :o7, 29601833, 12
- tz.transition 2042, 3, :o8, 29603681, 12
- tz.transition 2042, 10, :o7, 29606201, 12
- tz.transition 2043, 3, :o8, 29608049, 12
- tz.transition 2043, 10, :o7, 29610569, 12
- tz.transition 2044, 3, :o8, 29612417, 12
- tz.transition 2044, 10, :o7, 29615021, 12
- tz.transition 2045, 3, :o8, 29616785, 12
- tz.transition 2045, 10, :o7, 29619389, 12
- tz.transition 2046, 3, :o8, 29621153, 12
- tz.transition 2046, 10, :o7, 29623757, 12
- tz.transition 2047, 3, :o8, 29625605, 12
- tz.transition 2047, 10, :o7, 29628125, 12
- tz.transition 2048, 3, :o8, 29629973, 12
- tz.transition 2048, 10, :o7, 29632493, 12
- tz.transition 2049, 3, :o8, 29634341, 12
- tz.transition 2049, 10, :o7, 29636945, 12
- tz.transition 2050, 3, :o8, 29638709, 12
- tz.transition 2050, 10, :o7, 29641313, 12
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Atlantic/Azores.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Atlantic/Azores.rb
deleted file mode 100644
index 1bd16a75ac..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Atlantic/Azores.rb
+++ /dev/null
@@ -1,270 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Atlantic
- module Azores
- include TimezoneDefinition
-
- timezone 'Atlantic/Azores' do |tz|
- tz.offset :o0, -6160, 0, :LMT
- tz.offset :o1, -6872, 0, :HMT
- tz.offset :o2, -7200, 0, :AZOT
- tz.offset :o3, -7200, 3600, :AZOST
- tz.offset :o4, -7200, 7200, :AZOMT
- tz.offset :o5, -3600, 0, :AZOT
- tz.offset :o6, -3600, 3600, :AZOST
- tz.offset :o7, 0, 0, :WET
-
- tz.transition 1884, 1, :o1, 2601910697, 1080
- tz.transition 1911, 5, :o2, 26127150259, 10800
- tz.transition 1916, 6, :o3, 58104781, 24
- tz.transition 1916, 11, :o2, 29054023, 12
- tz.transition 1917, 3, :o3, 58110925, 24
- tz.transition 1917, 10, :o2, 58116397, 24
- tz.transition 1918, 3, :o3, 58119709, 24
- tz.transition 1918, 10, :o2, 58125157, 24
- tz.transition 1919, 3, :o3, 58128445, 24
- tz.transition 1919, 10, :o2, 58133917, 24
- tz.transition 1920, 3, :o3, 58137229, 24
- tz.transition 1920, 10, :o2, 58142701, 24
- tz.transition 1921, 3, :o3, 58145989, 24
- tz.transition 1921, 10, :o2, 58151461, 24
- tz.transition 1924, 4, :o3, 58173421, 24
- tz.transition 1924, 10, :o2, 58177765, 24
- tz.transition 1926, 4, :o3, 58190965, 24
- tz.transition 1926, 10, :o2, 58194997, 24
- tz.transition 1927, 4, :o3, 58199533, 24
- tz.transition 1927, 10, :o2, 58203733, 24
- tz.transition 1928, 4, :o3, 58208437, 24
- tz.transition 1928, 10, :o2, 58212637, 24
- tz.transition 1929, 4, :o3, 58217341, 24
- tz.transition 1929, 10, :o2, 58221373, 24
- tz.transition 1931, 4, :o3, 58234813, 24
- tz.transition 1931, 10, :o2, 58238845, 24
- tz.transition 1932, 4, :o3, 58243213, 24
- tz.transition 1932, 10, :o2, 58247581, 24
- tz.transition 1934, 4, :o3, 58260853, 24
- tz.transition 1934, 10, :o2, 58265221, 24
- tz.transition 1935, 3, :o3, 58269421, 24
- tz.transition 1935, 10, :o2, 58273957, 24
- tz.transition 1936, 4, :o3, 58278661, 24
- tz.transition 1936, 10, :o2, 58282693, 24
- tz.transition 1937, 4, :o3, 58287061, 24
- tz.transition 1937, 10, :o2, 58291429, 24
- tz.transition 1938, 3, :o3, 58295629, 24
- tz.transition 1938, 10, :o2, 58300165, 24
- tz.transition 1939, 4, :o3, 58304869, 24
- tz.transition 1939, 11, :o2, 58310077, 24
- tz.transition 1940, 2, :o3, 58312429, 24
- tz.transition 1940, 10, :o2, 58317805, 24
- tz.transition 1941, 4, :o3, 58322173, 24
- tz.transition 1941, 10, :o2, 58326565, 24
- tz.transition 1942, 3, :o3, 58330405, 24
- tz.transition 1942, 4, :o4, 4860951, 2
- tz.transition 1942, 8, :o3, 4861175, 2
- tz.transition 1942, 10, :o2, 58335781, 24
- tz.transition 1943, 3, :o3, 58339141, 24
- tz.transition 1943, 4, :o4, 4861665, 2
- tz.transition 1943, 8, :o3, 4861931, 2
- tz.transition 1943, 10, :o2, 58344685, 24
- tz.transition 1944, 3, :o3, 58347877, 24
- tz.transition 1944, 4, :o4, 4862407, 2
- tz.transition 1944, 8, :o3, 4862659, 2
- tz.transition 1944, 10, :o2, 58353421, 24
- tz.transition 1945, 3, :o3, 58356613, 24
- tz.transition 1945, 4, :o4, 4863135, 2
- tz.transition 1945, 8, :o3, 4863387, 2
- tz.transition 1945, 10, :o2, 58362157, 24
- tz.transition 1946, 4, :o3, 58366021, 24
- tz.transition 1946, 10, :o2, 58370389, 24
- tz.transition 1947, 4, :o3, 7296845, 3
- tz.transition 1947, 10, :o2, 7297391, 3
- tz.transition 1948, 4, :o3, 7297937, 3
- tz.transition 1948, 10, :o2, 7298483, 3
- tz.transition 1949, 4, :o3, 7299029, 3
- tz.transition 1949, 10, :o2, 7299575, 3
- tz.transition 1951, 4, :o3, 7301213, 3
- tz.transition 1951, 10, :o2, 7301780, 3
- tz.transition 1952, 4, :o3, 7302326, 3
- tz.transition 1952, 10, :o2, 7302872, 3
- tz.transition 1953, 4, :o3, 7303418, 3
- tz.transition 1953, 10, :o2, 7303964, 3
- tz.transition 1954, 4, :o3, 7304510, 3
- tz.transition 1954, 10, :o2, 7305056, 3
- tz.transition 1955, 4, :o3, 7305602, 3
- tz.transition 1955, 10, :o2, 7306148, 3
- tz.transition 1956, 4, :o3, 7306694, 3
- tz.transition 1956, 10, :o2, 7307261, 3
- tz.transition 1957, 4, :o3, 7307807, 3
- tz.transition 1957, 10, :o2, 7308353, 3
- tz.transition 1958, 4, :o3, 7308899, 3
- tz.transition 1958, 10, :o2, 7309445, 3
- tz.transition 1959, 4, :o3, 7309991, 3
- tz.transition 1959, 10, :o2, 7310537, 3
- tz.transition 1960, 4, :o3, 7311083, 3
- tz.transition 1960, 10, :o2, 7311629, 3
- tz.transition 1961, 4, :o3, 7312175, 3
- tz.transition 1961, 10, :o2, 7312721, 3
- tz.transition 1962, 4, :o3, 7313267, 3
- tz.transition 1962, 10, :o2, 7313834, 3
- tz.transition 1963, 4, :o3, 7314380, 3
- tz.transition 1963, 10, :o2, 7314926, 3
- tz.transition 1964, 4, :o3, 7315472, 3
- tz.transition 1964, 10, :o2, 7316018, 3
- tz.transition 1965, 4, :o3, 7316564, 3
- tz.transition 1965, 10, :o2, 7317110, 3
- tz.transition 1966, 4, :o5, 7317656, 3
- tz.transition 1977, 3, :o6, 228272400
- tz.transition 1977, 9, :o5, 243997200
- tz.transition 1978, 4, :o6, 260326800
- tz.transition 1978, 10, :o5, 276051600
- tz.transition 1979, 4, :o6, 291776400
- tz.transition 1979, 9, :o5, 307504800
- tz.transition 1980, 3, :o6, 323226000
- tz.transition 1980, 9, :o5, 338954400
- tz.transition 1981, 3, :o6, 354679200
- tz.transition 1981, 9, :o5, 370404000
- tz.transition 1982, 3, :o6, 386128800
- tz.transition 1982, 9, :o5, 401853600
- tz.transition 1983, 3, :o6, 417582000
- tz.transition 1983, 9, :o5, 433303200
- tz.transition 1984, 3, :o6, 449028000
- tz.transition 1984, 9, :o5, 465357600
- tz.transition 1985, 3, :o6, 481082400
- tz.transition 1985, 9, :o5, 496807200
- tz.transition 1986, 3, :o6, 512532000
- tz.transition 1986, 9, :o5, 528256800
- tz.transition 1987, 3, :o6, 543981600
- tz.transition 1987, 9, :o5, 559706400
- tz.transition 1988, 3, :o6, 575431200
- tz.transition 1988, 9, :o5, 591156000
- tz.transition 1989, 3, :o6, 606880800
- tz.transition 1989, 9, :o5, 622605600
- tz.transition 1990, 3, :o6, 638330400
- tz.transition 1990, 9, :o5, 654660000
- tz.transition 1991, 3, :o6, 670384800
- tz.transition 1991, 9, :o5, 686109600
- tz.transition 1992, 3, :o6, 701834400
- tz.transition 1992, 9, :o7, 717559200
- tz.transition 1993, 3, :o6, 733280400
- tz.transition 1993, 9, :o5, 749005200
- tz.transition 1994, 3, :o6, 764730000
- tz.transition 1994, 9, :o5, 780454800
- tz.transition 1995, 3, :o6, 796179600
- tz.transition 1995, 9, :o5, 811904400
- tz.transition 1996, 3, :o6, 828234000
- tz.transition 1996, 10, :o5, 846378000
- tz.transition 1997, 3, :o6, 859683600
- tz.transition 1997, 10, :o5, 877827600
- tz.transition 1998, 3, :o6, 891133200
- tz.transition 1998, 10, :o5, 909277200
- tz.transition 1999, 3, :o6, 922582800
- tz.transition 1999, 10, :o5, 941331600
- tz.transition 2000, 3, :o6, 954032400
- tz.transition 2000, 10, :o5, 972781200
- tz.transition 2001, 3, :o6, 985482000
- tz.transition 2001, 10, :o5, 1004230800
- tz.transition 2002, 3, :o6, 1017536400
- tz.transition 2002, 10, :o5, 1035680400
- tz.transition 2003, 3, :o6, 1048986000
- tz.transition 2003, 10, :o5, 1067130000
- tz.transition 2004, 3, :o6, 1080435600
- tz.transition 2004, 10, :o5, 1099184400
- tz.transition 2005, 3, :o6, 1111885200
- tz.transition 2005, 10, :o5, 1130634000
- tz.transition 2006, 3, :o6, 1143334800
- tz.transition 2006, 10, :o5, 1162083600
- tz.transition 2007, 3, :o6, 1174784400
- tz.transition 2007, 10, :o5, 1193533200
- tz.transition 2008, 3, :o6, 1206838800
- tz.transition 2008, 10, :o5, 1224982800
- tz.transition 2009, 3, :o6, 1238288400
- tz.transition 2009, 10, :o5, 1256432400
- tz.transition 2010, 3, :o6, 1269738000
- tz.transition 2010, 10, :o5, 1288486800
- tz.transition 2011, 3, :o6, 1301187600
- tz.transition 2011, 10, :o5, 1319936400
- tz.transition 2012, 3, :o6, 1332637200
- tz.transition 2012, 10, :o5, 1351386000
- tz.transition 2013, 3, :o6, 1364691600
- tz.transition 2013, 10, :o5, 1382835600
- tz.transition 2014, 3, :o6, 1396141200
- tz.transition 2014, 10, :o5, 1414285200
- tz.transition 2015, 3, :o6, 1427590800
- tz.transition 2015, 10, :o5, 1445734800
- tz.transition 2016, 3, :o6, 1459040400
- tz.transition 2016, 10, :o5, 1477789200
- tz.transition 2017, 3, :o6, 1490490000
- tz.transition 2017, 10, :o5, 1509238800
- tz.transition 2018, 3, :o6, 1521939600
- tz.transition 2018, 10, :o5, 1540688400
- tz.transition 2019, 3, :o6, 1553994000
- tz.transition 2019, 10, :o5, 1572138000
- tz.transition 2020, 3, :o6, 1585443600
- tz.transition 2020, 10, :o5, 1603587600
- tz.transition 2021, 3, :o6, 1616893200
- tz.transition 2021, 10, :o5, 1635642000
- tz.transition 2022, 3, :o6, 1648342800
- tz.transition 2022, 10, :o5, 1667091600
- tz.transition 2023, 3, :o6, 1679792400
- tz.transition 2023, 10, :o5, 1698541200
- tz.transition 2024, 3, :o6, 1711846800
- tz.transition 2024, 10, :o5, 1729990800
- tz.transition 2025, 3, :o6, 1743296400
- tz.transition 2025, 10, :o5, 1761440400
- tz.transition 2026, 3, :o6, 1774746000
- tz.transition 2026, 10, :o5, 1792890000
- tz.transition 2027, 3, :o6, 1806195600
- tz.transition 2027, 10, :o5, 1824944400
- tz.transition 2028, 3, :o6, 1837645200
- tz.transition 2028, 10, :o5, 1856394000
- tz.transition 2029, 3, :o6, 1869094800
- tz.transition 2029, 10, :o5, 1887843600
- tz.transition 2030, 3, :o6, 1901149200
- tz.transition 2030, 10, :o5, 1919293200
- tz.transition 2031, 3, :o6, 1932598800
- tz.transition 2031, 10, :o5, 1950742800
- tz.transition 2032, 3, :o6, 1964048400
- tz.transition 2032, 10, :o5, 1982797200
- tz.transition 2033, 3, :o6, 1995498000
- tz.transition 2033, 10, :o5, 2014246800
- tz.transition 2034, 3, :o6, 2026947600
- tz.transition 2034, 10, :o5, 2045696400
- tz.transition 2035, 3, :o6, 2058397200
- tz.transition 2035, 10, :o5, 2077146000
- tz.transition 2036, 3, :o6, 2090451600
- tz.transition 2036, 10, :o5, 2108595600
- tz.transition 2037, 3, :o6, 2121901200
- tz.transition 2037, 10, :o5, 2140045200
- tz.transition 2038, 3, :o6, 59172253, 24
- tz.transition 2038, 10, :o5, 59177461, 24
- tz.transition 2039, 3, :o6, 59180989, 24
- tz.transition 2039, 10, :o5, 59186197, 24
- tz.transition 2040, 3, :o6, 59189725, 24
- tz.transition 2040, 10, :o5, 59194933, 24
- tz.transition 2041, 3, :o6, 59198629, 24
- tz.transition 2041, 10, :o5, 59203669, 24
- tz.transition 2042, 3, :o6, 59207365, 24
- tz.transition 2042, 10, :o5, 59212405, 24
- tz.transition 2043, 3, :o6, 59216101, 24
- tz.transition 2043, 10, :o5, 59221141, 24
- tz.transition 2044, 3, :o6, 59224837, 24
- tz.transition 2044, 10, :o5, 59230045, 24
- tz.transition 2045, 3, :o6, 59233573, 24
- tz.transition 2045, 10, :o5, 59238781, 24
- tz.transition 2046, 3, :o6, 59242309, 24
- tz.transition 2046, 10, :o5, 59247517, 24
- tz.transition 2047, 3, :o6, 59251213, 24
- tz.transition 2047, 10, :o5, 59256253, 24
- tz.transition 2048, 3, :o6, 59259949, 24
- tz.transition 2048, 10, :o5, 59264989, 24
- tz.transition 2049, 3, :o6, 59268685, 24
- tz.transition 2049, 10, :o5, 59273893, 24
- tz.transition 2050, 3, :o6, 59277421, 24
- tz.transition 2050, 10, :o5, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Atlantic/Cape_Verde.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Atlantic/Cape_Verde.rb
deleted file mode 100644
index 61c8c15043..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Atlantic/Cape_Verde.rb
+++ /dev/null
@@ -1,23 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Atlantic
- module Cape_Verde
- include TimezoneDefinition
-
- timezone 'Atlantic/Cape_Verde' do |tz|
- tz.offset :o0, -5644, 0, :LMT
- tz.offset :o1, -7200, 0, :CVT
- tz.offset :o2, -7200, 3600, :CVST
- tz.offset :o3, -3600, 0, :CVT
-
- tz.transition 1907, 1, :o1, 52219653811, 21600
- tz.transition 1942, 9, :o2, 29167243, 12
- tz.transition 1945, 10, :o1, 58361845, 24
- tz.transition 1975, 11, :o3, 186120000
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Atlantic/South_Georgia.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Atlantic/South_Georgia.rb
deleted file mode 100644
index 6a4cbafb9f..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Atlantic/South_Georgia.rb
+++ /dev/null
@@ -1,18 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Atlantic
- module South_Georgia
- include TimezoneDefinition
-
- timezone 'Atlantic/South_Georgia' do |tz|
- tz.offset :o0, -8768, 0, :LMT
- tz.offset :o1, -7200, 0, :GST
-
- tz.transition 1890, 1, :o1, 1627673806, 675
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Adelaide.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Adelaide.rb
deleted file mode 100644
index c5d561cc1e..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Adelaide.rb
+++ /dev/null
@@ -1,187 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Australia
- module Adelaide
- include TimezoneDefinition
-
- timezone 'Australia/Adelaide' do |tz|
- tz.offset :o0, 33260, 0, :LMT
- tz.offset :o1, 32400, 0, :CST
- tz.offset :o2, 34200, 0, :CST
- tz.offset :o3, 34200, 3600, :CST
-
- tz.transition 1895, 1, :o1, 10425132497, 4320
- tz.transition 1899, 4, :o2, 19318201, 8
- tz.transition 1916, 12, :o3, 3486569911, 1440
- tz.transition 1917, 3, :o2, 116222983, 48
- tz.transition 1941, 12, :o3, 38885763, 16
- tz.transition 1942, 3, :o2, 116661463, 48
- tz.transition 1942, 9, :o3, 38890067, 16
- tz.transition 1943, 3, :o2, 116678935, 48
- tz.transition 1943, 10, :o3, 38896003, 16
- tz.transition 1944, 3, :o2, 116696407, 48
- tz.transition 1971, 10, :o3, 57688200
- tz.transition 1972, 2, :o2, 67969800
- tz.transition 1972, 10, :o3, 89137800
- tz.transition 1973, 3, :o2, 100024200
- tz.transition 1973, 10, :o3, 120587400
- tz.transition 1974, 3, :o2, 131473800
- tz.transition 1974, 10, :o3, 152037000
- tz.transition 1975, 3, :o2, 162923400
- tz.transition 1975, 10, :o3, 183486600
- tz.transition 1976, 3, :o2, 194977800
- tz.transition 1976, 10, :o3, 215541000
- tz.transition 1977, 3, :o2, 226427400
- tz.transition 1977, 10, :o3, 246990600
- tz.transition 1978, 3, :o2, 257877000
- tz.transition 1978, 10, :o3, 278440200
- tz.transition 1979, 3, :o2, 289326600
- tz.transition 1979, 10, :o3, 309889800
- tz.transition 1980, 3, :o2, 320776200
- tz.transition 1980, 10, :o3, 341339400
- tz.transition 1981, 2, :o2, 352225800
- tz.transition 1981, 10, :o3, 372789000
- tz.transition 1982, 3, :o2, 384280200
- tz.transition 1982, 10, :o3, 404843400
- tz.transition 1983, 3, :o2, 415729800
- tz.transition 1983, 10, :o3, 436293000
- tz.transition 1984, 3, :o2, 447179400
- tz.transition 1984, 10, :o3, 467742600
- tz.transition 1985, 3, :o2, 478629000
- tz.transition 1985, 10, :o3, 499192200
- tz.transition 1986, 3, :o2, 511288200
- tz.transition 1986, 10, :o3, 530037000
- tz.transition 1987, 3, :o2, 542737800
- tz.transition 1987, 10, :o3, 562091400
- tz.transition 1988, 3, :o2, 574792200
- tz.transition 1988, 10, :o3, 594145800
- tz.transition 1989, 3, :o2, 606241800
- tz.transition 1989, 10, :o3, 625595400
- tz.transition 1990, 3, :o2, 637691400
- tz.transition 1990, 10, :o3, 657045000
- tz.transition 1991, 3, :o2, 667931400
- tz.transition 1991, 10, :o3, 688494600
- tz.transition 1992, 3, :o2, 701195400
- tz.transition 1992, 10, :o3, 719944200
- tz.transition 1993, 3, :o2, 731435400
- tz.transition 1993, 10, :o3, 751998600
- tz.transition 1994, 3, :o2, 764094600
- tz.transition 1994, 10, :o3, 783448200
- tz.transition 1995, 3, :o2, 796149000
- tz.transition 1995, 10, :o3, 814897800
- tz.transition 1996, 3, :o2, 828203400
- tz.transition 1996, 10, :o3, 846347400
- tz.transition 1997, 3, :o2, 859653000
- tz.transition 1997, 10, :o3, 877797000
- tz.transition 1998, 3, :o2, 891102600
- tz.transition 1998, 10, :o3, 909246600
- tz.transition 1999, 3, :o2, 922552200
- tz.transition 1999, 10, :o3, 941301000
- tz.transition 2000, 3, :o2, 954001800
- tz.transition 2000, 10, :o3, 972750600
- tz.transition 2001, 3, :o2, 985451400
- tz.transition 2001, 10, :o3, 1004200200
- tz.transition 2002, 3, :o2, 1017505800
- tz.transition 2002, 10, :o3, 1035649800
- tz.transition 2003, 3, :o2, 1048955400
- tz.transition 2003, 10, :o3, 1067099400
- tz.transition 2004, 3, :o2, 1080405000
- tz.transition 2004, 10, :o3, 1099153800
- tz.transition 2005, 3, :o2, 1111854600
- tz.transition 2005, 10, :o3, 1130603400
- tz.transition 2006, 4, :o2, 1143909000
- tz.transition 2006, 10, :o3, 1162053000
- tz.transition 2007, 3, :o2, 1174753800
- tz.transition 2007, 10, :o3, 1193502600
- tz.transition 2008, 4, :o2, 1207413000
- tz.transition 2008, 10, :o3, 1223137800
- tz.transition 2009, 4, :o2, 1238862600
- tz.transition 2009, 10, :o3, 1254587400
- tz.transition 2010, 4, :o2, 1270312200
- tz.transition 2010, 10, :o3, 1286037000
- tz.transition 2011, 4, :o2, 1301761800
- tz.transition 2011, 10, :o3, 1317486600
- tz.transition 2012, 3, :o2, 1333211400
- tz.transition 2012, 10, :o3, 1349541000
- tz.transition 2013, 4, :o2, 1365265800
- tz.transition 2013, 10, :o3, 1380990600
- tz.transition 2014, 4, :o2, 1396715400
- tz.transition 2014, 10, :o3, 1412440200
- tz.transition 2015, 4, :o2, 1428165000
- tz.transition 2015, 10, :o3, 1443889800
- tz.transition 2016, 4, :o2, 1459614600
- tz.transition 2016, 10, :o3, 1475339400
- tz.transition 2017, 4, :o2, 1491064200
- tz.transition 2017, 9, :o3, 1506789000
- tz.transition 2018, 3, :o2, 1522513800
- tz.transition 2018, 10, :o3, 1538843400
- tz.transition 2019, 4, :o2, 1554568200
- tz.transition 2019, 10, :o3, 1570293000
- tz.transition 2020, 4, :o2, 1586017800
- tz.transition 2020, 10, :o3, 1601742600
- tz.transition 2021, 4, :o2, 1617467400
- tz.transition 2021, 10, :o3, 1633192200
- tz.transition 2022, 4, :o2, 1648917000
- tz.transition 2022, 10, :o3, 1664641800
- tz.transition 2023, 4, :o2, 1680366600
- tz.transition 2023, 9, :o3, 1696091400
- tz.transition 2024, 4, :o2, 1712421000
- tz.transition 2024, 10, :o3, 1728145800
- tz.transition 2025, 4, :o2, 1743870600
- tz.transition 2025, 10, :o3, 1759595400
- tz.transition 2026, 4, :o2, 1775320200
- tz.transition 2026, 10, :o3, 1791045000
- tz.transition 2027, 4, :o2, 1806769800
- tz.transition 2027, 10, :o3, 1822494600
- tz.transition 2028, 4, :o2, 1838219400
- tz.transition 2028, 9, :o3, 1853944200
- tz.transition 2029, 3, :o2, 1869669000
- tz.transition 2029, 10, :o3, 1885998600
- tz.transition 2030, 4, :o2, 1901723400
- tz.transition 2030, 10, :o3, 1917448200
- tz.transition 2031, 4, :o2, 1933173000
- tz.transition 2031, 10, :o3, 1948897800
- tz.transition 2032, 4, :o2, 1964622600
- tz.transition 2032, 10, :o3, 1980347400
- tz.transition 2033, 4, :o2, 1996072200
- tz.transition 2033, 10, :o3, 2011797000
- tz.transition 2034, 4, :o2, 2027521800
- tz.transition 2034, 9, :o3, 2043246600
- tz.transition 2035, 3, :o2, 2058971400
- tz.transition 2035, 10, :o3, 2075301000
- tz.transition 2036, 4, :o2, 2091025800
- tz.transition 2036, 10, :o3, 2106750600
- tz.transition 2037, 4, :o2, 2122475400
- tz.transition 2037, 10, :o3, 2138200200
- tz.transition 2038, 4, :o2, 39448275, 16
- tz.transition 2038, 10, :o3, 39451187, 16
- tz.transition 2039, 4, :o2, 39454099, 16
- tz.transition 2039, 10, :o3, 39457011, 16
- tz.transition 2040, 3, :o2, 39459923, 16
- tz.transition 2040, 10, :o3, 39462947, 16
- tz.transition 2041, 4, :o2, 39465859, 16
- tz.transition 2041, 10, :o3, 39468771, 16
- tz.transition 2042, 4, :o2, 39471683, 16
- tz.transition 2042, 10, :o3, 39474595, 16
- tz.transition 2043, 4, :o2, 39477507, 16
- tz.transition 2043, 10, :o3, 39480419, 16
- tz.transition 2044, 4, :o2, 39483331, 16
- tz.transition 2044, 10, :o3, 39486243, 16
- tz.transition 2045, 4, :o2, 39489155, 16
- tz.transition 2045, 9, :o3, 39492067, 16
- tz.transition 2046, 3, :o2, 39494979, 16
- tz.transition 2046, 10, :o3, 39498003, 16
- tz.transition 2047, 4, :o2, 39500915, 16
- tz.transition 2047, 10, :o3, 39503827, 16
- tz.transition 2048, 4, :o2, 39506739, 16
- tz.transition 2048, 10, :o3, 39509651, 16
- tz.transition 2049, 4, :o2, 39512563, 16
- tz.transition 2049, 10, :o3, 39515475, 16
- tz.transition 2050, 4, :o2, 39518387, 16
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Brisbane.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Brisbane.rb
deleted file mode 100644
index dd85ddae94..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Brisbane.rb
+++ /dev/null
@@ -1,35 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Australia
- module Brisbane
- include TimezoneDefinition
-
- timezone 'Australia/Brisbane' do |tz|
- tz.offset :o0, 36728, 0, :LMT
- tz.offset :o1, 36000, 0, :EST
- tz.offset :o2, 36000, 3600, :EST
-
- tz.transition 1894, 12, :o1, 26062496009, 10800
- tz.transition 1916, 12, :o2, 3486569881, 1440
- tz.transition 1917, 3, :o1, 19370497, 8
- tz.transition 1941, 12, :o2, 14582161, 6
- tz.transition 1942, 3, :o1, 19443577, 8
- tz.transition 1942, 9, :o2, 14583775, 6
- tz.transition 1943, 3, :o1, 19446489, 8
- tz.transition 1943, 10, :o2, 14586001, 6
- tz.transition 1944, 3, :o1, 19449401, 8
- tz.transition 1971, 10, :o2, 57686400
- tz.transition 1972, 2, :o1, 67968000
- tz.transition 1989, 10, :o2, 625593600
- tz.transition 1990, 3, :o1, 636480000
- tz.transition 1990, 10, :o2, 657043200
- tz.transition 1991, 3, :o1, 667929600
- tz.transition 1991, 10, :o2, 688492800
- tz.transition 1992, 2, :o1, 699379200
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Darwin.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Darwin.rb
deleted file mode 100644
index 17de88124d..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Darwin.rb
+++ /dev/null
@@ -1,29 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Australia
- module Darwin
- include TimezoneDefinition
-
- timezone 'Australia/Darwin' do |tz|
- tz.offset :o0, 31400, 0, :LMT
- tz.offset :o1, 32400, 0, :CST
- tz.offset :o2, 34200, 0, :CST
- tz.offset :o3, 34200, 3600, :CST
-
- tz.transition 1895, 1, :o1, 1042513259, 432
- tz.transition 1899, 4, :o2, 19318201, 8
- tz.transition 1916, 12, :o3, 3486569911, 1440
- tz.transition 1917, 3, :o2, 116222983, 48
- tz.transition 1941, 12, :o3, 38885763, 16
- tz.transition 1942, 3, :o2, 116661463, 48
- tz.transition 1942, 9, :o3, 38890067, 16
- tz.transition 1943, 3, :o2, 116678935, 48
- tz.transition 1943, 10, :o3, 38896003, 16
- tz.transition 1944, 3, :o2, 116696407, 48
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Hobart.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Hobart.rb
deleted file mode 100644
index 11384b9840..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Hobart.rb
+++ /dev/null
@@ -1,193 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Australia
- module Hobart
- include TimezoneDefinition
-
- timezone 'Australia/Hobart' do |tz|
- tz.offset :o0, 35356, 0, :LMT
- tz.offset :o1, 36000, 0, :EST
- tz.offset :o2, 36000, 3600, :EST
-
- tz.transition 1895, 8, :o1, 52130241161, 21600
- tz.transition 1916, 9, :o2, 14526823, 6
- tz.transition 1917, 3, :o1, 19370497, 8
- tz.transition 1941, 12, :o2, 14582161, 6
- tz.transition 1942, 3, :o1, 19443577, 8
- tz.transition 1942, 9, :o2, 14583775, 6
- tz.transition 1943, 3, :o1, 19446489, 8
- tz.transition 1943, 10, :o2, 14586001, 6
- tz.transition 1944, 3, :o1, 19449401, 8
- tz.transition 1967, 9, :o2, 14638585, 6
- tz.transition 1968, 3, :o1, 14639677, 6
- tz.transition 1968, 10, :o2, 14640937, 6
- tz.transition 1969, 3, :o1, 14641735, 6
- tz.transition 1969, 10, :o2, 14643121, 6
- tz.transition 1970, 3, :o1, 5673600
- tz.transition 1970, 10, :o2, 25632000
- tz.transition 1971, 3, :o1, 37728000
- tz.transition 1971, 10, :o2, 57686400
- tz.transition 1972, 2, :o1, 67968000
- tz.transition 1972, 10, :o2, 89136000
- tz.transition 1973, 3, :o1, 100022400
- tz.transition 1973, 10, :o2, 120585600
- tz.transition 1974, 3, :o1, 131472000
- tz.transition 1974, 10, :o2, 152035200
- tz.transition 1975, 3, :o1, 162921600
- tz.transition 1975, 10, :o2, 183484800
- tz.transition 1976, 3, :o1, 194976000
- tz.transition 1976, 10, :o2, 215539200
- tz.transition 1977, 3, :o1, 226425600
- tz.transition 1977, 10, :o2, 246988800
- tz.transition 1978, 3, :o1, 257875200
- tz.transition 1978, 10, :o2, 278438400
- tz.transition 1979, 3, :o1, 289324800
- tz.transition 1979, 10, :o2, 309888000
- tz.transition 1980, 3, :o1, 320774400
- tz.transition 1980, 10, :o2, 341337600
- tz.transition 1981, 2, :o1, 352224000
- tz.transition 1981, 10, :o2, 372787200
- tz.transition 1982, 3, :o1, 386092800
- tz.transition 1982, 10, :o2, 404841600
- tz.transition 1983, 3, :o1, 417542400
- tz.transition 1983, 10, :o2, 436291200
- tz.transition 1984, 3, :o1, 447177600
- tz.transition 1984, 10, :o2, 467740800
- tz.transition 1985, 3, :o1, 478627200
- tz.transition 1985, 10, :o2, 499190400
- tz.transition 1986, 3, :o1, 510076800
- tz.transition 1986, 10, :o2, 530035200
- tz.transition 1987, 3, :o1, 542736000
- tz.transition 1987, 10, :o2, 562089600
- tz.transition 1988, 3, :o1, 574790400
- tz.transition 1988, 10, :o2, 594144000
- tz.transition 1989, 3, :o1, 606240000
- tz.transition 1989, 10, :o2, 625593600
- tz.transition 1990, 3, :o1, 637689600
- tz.transition 1990, 10, :o2, 657043200
- tz.transition 1991, 3, :o1, 670348800
- tz.transition 1991, 10, :o2, 686678400
- tz.transition 1992, 3, :o1, 701798400
- tz.transition 1992, 10, :o2, 718128000
- tz.transition 1993, 3, :o1, 733248000
- tz.transition 1993, 10, :o2, 749577600
- tz.transition 1994, 3, :o1, 764697600
- tz.transition 1994, 10, :o2, 781027200
- tz.transition 1995, 3, :o1, 796147200
- tz.transition 1995, 9, :o2, 812476800
- tz.transition 1996, 3, :o1, 828201600
- tz.transition 1996, 10, :o2, 844531200
- tz.transition 1997, 3, :o1, 859651200
- tz.transition 1997, 10, :o2, 875980800
- tz.transition 1998, 3, :o1, 891100800
- tz.transition 1998, 10, :o2, 907430400
- tz.transition 1999, 3, :o1, 922550400
- tz.transition 1999, 10, :o2, 938880000
- tz.transition 2000, 3, :o1, 954000000
- tz.transition 2000, 8, :o2, 967305600
- tz.transition 2001, 3, :o1, 985449600
- tz.transition 2001, 10, :o2, 1002384000
- tz.transition 2002, 3, :o1, 1017504000
- tz.transition 2002, 10, :o2, 1033833600
- tz.transition 2003, 3, :o1, 1048953600
- tz.transition 2003, 10, :o2, 1065283200
- tz.transition 2004, 3, :o1, 1080403200
- tz.transition 2004, 10, :o2, 1096732800
- tz.transition 2005, 3, :o1, 1111852800
- tz.transition 2005, 10, :o2, 1128182400
- tz.transition 2006, 4, :o1, 1143907200
- tz.transition 2006, 9, :o2, 1159632000
- tz.transition 2007, 3, :o1, 1174752000
- tz.transition 2007, 10, :o2, 1191686400
- tz.transition 2008, 4, :o1, 1207411200
- tz.transition 2008, 10, :o2, 1223136000
- tz.transition 2009, 4, :o1, 1238860800
- tz.transition 2009, 10, :o2, 1254585600
- tz.transition 2010, 4, :o1, 1270310400
- tz.transition 2010, 10, :o2, 1286035200
- tz.transition 2011, 4, :o1, 1301760000
- tz.transition 2011, 10, :o2, 1317484800
- tz.transition 2012, 3, :o1, 1333209600
- tz.transition 2012, 10, :o2, 1349539200
- tz.transition 2013, 4, :o1, 1365264000
- tz.transition 2013, 10, :o2, 1380988800
- tz.transition 2014, 4, :o1, 1396713600
- tz.transition 2014, 10, :o2, 1412438400
- tz.transition 2015, 4, :o1, 1428163200
- tz.transition 2015, 10, :o2, 1443888000
- tz.transition 2016, 4, :o1, 1459612800
- tz.transition 2016, 10, :o2, 1475337600
- tz.transition 2017, 4, :o1, 1491062400
- tz.transition 2017, 9, :o2, 1506787200
- tz.transition 2018, 3, :o1, 1522512000
- tz.transition 2018, 10, :o2, 1538841600
- tz.transition 2019, 4, :o1, 1554566400
- tz.transition 2019, 10, :o2, 1570291200
- tz.transition 2020, 4, :o1, 1586016000
- tz.transition 2020, 10, :o2, 1601740800
- tz.transition 2021, 4, :o1, 1617465600
- tz.transition 2021, 10, :o2, 1633190400
- tz.transition 2022, 4, :o1, 1648915200
- tz.transition 2022, 10, :o2, 1664640000
- tz.transition 2023, 4, :o1, 1680364800
- tz.transition 2023, 9, :o2, 1696089600
- tz.transition 2024, 4, :o1, 1712419200
- tz.transition 2024, 10, :o2, 1728144000
- tz.transition 2025, 4, :o1, 1743868800
- tz.transition 2025, 10, :o2, 1759593600
- tz.transition 2026, 4, :o1, 1775318400
- tz.transition 2026, 10, :o2, 1791043200
- tz.transition 2027, 4, :o1, 1806768000
- tz.transition 2027, 10, :o2, 1822492800
- tz.transition 2028, 4, :o1, 1838217600
- tz.transition 2028, 9, :o2, 1853942400
- tz.transition 2029, 3, :o1, 1869667200
- tz.transition 2029, 10, :o2, 1885996800
- tz.transition 2030, 4, :o1, 1901721600
- tz.transition 2030, 10, :o2, 1917446400
- tz.transition 2031, 4, :o1, 1933171200
- tz.transition 2031, 10, :o2, 1948896000
- tz.transition 2032, 4, :o1, 1964620800
- tz.transition 2032, 10, :o2, 1980345600
- tz.transition 2033, 4, :o1, 1996070400
- tz.transition 2033, 10, :o2, 2011795200
- tz.transition 2034, 4, :o1, 2027520000
- tz.transition 2034, 9, :o2, 2043244800
- tz.transition 2035, 3, :o1, 2058969600
- tz.transition 2035, 10, :o2, 2075299200
- tz.transition 2036, 4, :o1, 2091024000
- tz.transition 2036, 10, :o2, 2106748800
- tz.transition 2037, 4, :o1, 2122473600
- tz.transition 2037, 10, :o2, 2138198400
- tz.transition 2038, 4, :o1, 14793103, 6
- tz.transition 2038, 10, :o2, 14794195, 6
- tz.transition 2039, 4, :o1, 14795287, 6
- tz.transition 2039, 10, :o2, 14796379, 6
- tz.transition 2040, 3, :o1, 14797471, 6
- tz.transition 2040, 10, :o2, 14798605, 6
- tz.transition 2041, 4, :o1, 14799697, 6
- tz.transition 2041, 10, :o2, 14800789, 6
- tz.transition 2042, 4, :o1, 14801881, 6
- tz.transition 2042, 10, :o2, 14802973, 6
- tz.transition 2043, 4, :o1, 14804065, 6
- tz.transition 2043, 10, :o2, 14805157, 6
- tz.transition 2044, 4, :o1, 14806249, 6
- tz.transition 2044, 10, :o2, 14807341, 6
- tz.transition 2045, 4, :o1, 14808433, 6
- tz.transition 2045, 9, :o2, 14809525, 6
- tz.transition 2046, 3, :o1, 14810617, 6
- tz.transition 2046, 10, :o2, 14811751, 6
- tz.transition 2047, 4, :o1, 14812843, 6
- tz.transition 2047, 10, :o2, 14813935, 6
- tz.transition 2048, 4, :o1, 14815027, 6
- tz.transition 2048, 10, :o2, 14816119, 6
- tz.transition 2049, 4, :o1, 14817211, 6
- tz.transition 2049, 10, :o2, 14818303, 6
- tz.transition 2050, 4, :o1, 14819395, 6
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Melbourne.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Melbourne.rb
deleted file mode 100644
index c1304488ea..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Melbourne.rb
+++ /dev/null
@@ -1,185 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Australia
- module Melbourne
- include TimezoneDefinition
-
- timezone 'Australia/Melbourne' do |tz|
- tz.offset :o0, 34792, 0, :LMT
- tz.offset :o1, 36000, 0, :EST
- tz.offset :o2, 36000, 3600, :EST
-
- tz.transition 1895, 1, :o1, 26062831051, 10800
- tz.transition 1916, 12, :o2, 3486569881, 1440
- tz.transition 1917, 3, :o1, 19370497, 8
- tz.transition 1941, 12, :o2, 14582161, 6
- tz.transition 1942, 3, :o1, 19443577, 8
- tz.transition 1942, 9, :o2, 14583775, 6
- tz.transition 1943, 3, :o1, 19446489, 8
- tz.transition 1943, 10, :o2, 14586001, 6
- tz.transition 1944, 3, :o1, 19449401, 8
- tz.transition 1971, 10, :o2, 57686400
- tz.transition 1972, 2, :o1, 67968000
- tz.transition 1972, 10, :o2, 89136000
- tz.transition 1973, 3, :o1, 100022400
- tz.transition 1973, 10, :o2, 120585600
- tz.transition 1974, 3, :o1, 131472000
- tz.transition 1974, 10, :o2, 152035200
- tz.transition 1975, 3, :o1, 162921600
- tz.transition 1975, 10, :o2, 183484800
- tz.transition 1976, 3, :o1, 194976000
- tz.transition 1976, 10, :o2, 215539200
- tz.transition 1977, 3, :o1, 226425600
- tz.transition 1977, 10, :o2, 246988800
- tz.transition 1978, 3, :o1, 257875200
- tz.transition 1978, 10, :o2, 278438400
- tz.transition 1979, 3, :o1, 289324800
- tz.transition 1979, 10, :o2, 309888000
- tz.transition 1980, 3, :o1, 320774400
- tz.transition 1980, 10, :o2, 341337600
- tz.transition 1981, 2, :o1, 352224000
- tz.transition 1981, 10, :o2, 372787200
- tz.transition 1982, 3, :o1, 384278400
- tz.transition 1982, 10, :o2, 404841600
- tz.transition 1983, 3, :o1, 415728000
- tz.transition 1983, 10, :o2, 436291200
- tz.transition 1984, 3, :o1, 447177600
- tz.transition 1984, 10, :o2, 467740800
- tz.transition 1985, 3, :o1, 478627200
- tz.transition 1985, 10, :o2, 499190400
- tz.transition 1986, 3, :o1, 511286400
- tz.transition 1986, 10, :o2, 530035200
- tz.transition 1987, 3, :o1, 542736000
- tz.transition 1987, 10, :o2, 561484800
- tz.transition 1988, 3, :o1, 574790400
- tz.transition 1988, 10, :o2, 594144000
- tz.transition 1989, 3, :o1, 606240000
- tz.transition 1989, 10, :o2, 625593600
- tz.transition 1990, 3, :o1, 637689600
- tz.transition 1990, 10, :o2, 657043200
- tz.transition 1991, 3, :o1, 667929600
- tz.transition 1991, 10, :o2, 688492800
- tz.transition 1992, 2, :o1, 699379200
- tz.transition 1992, 10, :o2, 719942400
- tz.transition 1993, 3, :o1, 731433600
- tz.transition 1993, 10, :o2, 751996800
- tz.transition 1994, 3, :o1, 762883200
- tz.transition 1994, 10, :o2, 783446400
- tz.transition 1995, 3, :o1, 796147200
- tz.transition 1995, 10, :o2, 814896000
- tz.transition 1996, 3, :o1, 828201600
- tz.transition 1996, 10, :o2, 846345600
- tz.transition 1997, 3, :o1, 859651200
- tz.transition 1997, 10, :o2, 877795200
- tz.transition 1998, 3, :o1, 891100800
- tz.transition 1998, 10, :o2, 909244800
- tz.transition 1999, 3, :o1, 922550400
- tz.transition 1999, 10, :o2, 941299200
- tz.transition 2000, 3, :o1, 954000000
- tz.transition 2000, 8, :o2, 967305600
- tz.transition 2001, 3, :o1, 985449600
- tz.transition 2001, 10, :o2, 1004198400
- tz.transition 2002, 3, :o1, 1017504000
- tz.transition 2002, 10, :o2, 1035648000
- tz.transition 2003, 3, :o1, 1048953600
- tz.transition 2003, 10, :o2, 1067097600
- tz.transition 2004, 3, :o1, 1080403200
- tz.transition 2004, 10, :o2, 1099152000
- tz.transition 2005, 3, :o1, 1111852800
- tz.transition 2005, 10, :o2, 1130601600
- tz.transition 2006, 4, :o1, 1143907200
- tz.transition 2006, 10, :o2, 1162051200
- tz.transition 2007, 3, :o1, 1174752000
- tz.transition 2007, 10, :o2, 1193500800
- tz.transition 2008, 4, :o1, 1207411200
- tz.transition 2008, 10, :o2, 1223136000
- tz.transition 2009, 4, :o1, 1238860800
- tz.transition 2009, 10, :o2, 1254585600
- tz.transition 2010, 4, :o1, 1270310400
- tz.transition 2010, 10, :o2, 1286035200
- tz.transition 2011, 4, :o1, 1301760000
- tz.transition 2011, 10, :o2, 1317484800
- tz.transition 2012, 3, :o1, 1333209600
- tz.transition 2012, 10, :o2, 1349539200
- tz.transition 2013, 4, :o1, 1365264000
- tz.transition 2013, 10, :o2, 1380988800
- tz.transition 2014, 4, :o1, 1396713600
- tz.transition 2014, 10, :o2, 1412438400
- tz.transition 2015, 4, :o1, 1428163200
- tz.transition 2015, 10, :o2, 1443888000
- tz.transition 2016, 4, :o1, 1459612800
- tz.transition 2016, 10, :o2, 1475337600
- tz.transition 2017, 4, :o1, 1491062400
- tz.transition 2017, 9, :o2, 1506787200
- tz.transition 2018, 3, :o1, 1522512000
- tz.transition 2018, 10, :o2, 1538841600
- tz.transition 2019, 4, :o1, 1554566400
- tz.transition 2019, 10, :o2, 1570291200
- tz.transition 2020, 4, :o1, 1586016000
- tz.transition 2020, 10, :o2, 1601740800
- tz.transition 2021, 4, :o1, 1617465600
- tz.transition 2021, 10, :o2, 1633190400
- tz.transition 2022, 4, :o1, 1648915200
- tz.transition 2022, 10, :o2, 1664640000
- tz.transition 2023, 4, :o1, 1680364800
- tz.transition 2023, 9, :o2, 1696089600
- tz.transition 2024, 4, :o1, 1712419200
- tz.transition 2024, 10, :o2, 1728144000
- tz.transition 2025, 4, :o1, 1743868800
- tz.transition 2025, 10, :o2, 1759593600
- tz.transition 2026, 4, :o1, 1775318400
- tz.transition 2026, 10, :o2, 1791043200
- tz.transition 2027, 4, :o1, 1806768000
- tz.transition 2027, 10, :o2, 1822492800
- tz.transition 2028, 4, :o1, 1838217600
- tz.transition 2028, 9, :o2, 1853942400
- tz.transition 2029, 3, :o1, 1869667200
- tz.transition 2029, 10, :o2, 1885996800
- tz.transition 2030, 4, :o1, 1901721600
- tz.transition 2030, 10, :o2, 1917446400
- tz.transition 2031, 4, :o1, 1933171200
- tz.transition 2031, 10, :o2, 1948896000
- tz.transition 2032, 4, :o1, 1964620800
- tz.transition 2032, 10, :o2, 1980345600
- tz.transition 2033, 4, :o1, 1996070400
- tz.transition 2033, 10, :o2, 2011795200
- tz.transition 2034, 4, :o1, 2027520000
- tz.transition 2034, 9, :o2, 2043244800
- tz.transition 2035, 3, :o1, 2058969600
- tz.transition 2035, 10, :o2, 2075299200
- tz.transition 2036, 4, :o1, 2091024000
- tz.transition 2036, 10, :o2, 2106748800
- tz.transition 2037, 4, :o1, 2122473600
- tz.transition 2037, 10, :o2, 2138198400
- tz.transition 2038, 4, :o1, 14793103, 6
- tz.transition 2038, 10, :o2, 14794195, 6
- tz.transition 2039, 4, :o1, 14795287, 6
- tz.transition 2039, 10, :o2, 14796379, 6
- tz.transition 2040, 3, :o1, 14797471, 6
- tz.transition 2040, 10, :o2, 14798605, 6
- tz.transition 2041, 4, :o1, 14799697, 6
- tz.transition 2041, 10, :o2, 14800789, 6
- tz.transition 2042, 4, :o1, 14801881, 6
- tz.transition 2042, 10, :o2, 14802973, 6
- tz.transition 2043, 4, :o1, 14804065, 6
- tz.transition 2043, 10, :o2, 14805157, 6
- tz.transition 2044, 4, :o1, 14806249, 6
- tz.transition 2044, 10, :o2, 14807341, 6
- tz.transition 2045, 4, :o1, 14808433, 6
- tz.transition 2045, 9, :o2, 14809525, 6
- tz.transition 2046, 3, :o1, 14810617, 6
- tz.transition 2046, 10, :o2, 14811751, 6
- tz.transition 2047, 4, :o1, 14812843, 6
- tz.transition 2047, 10, :o2, 14813935, 6
- tz.transition 2048, 4, :o1, 14815027, 6
- tz.transition 2048, 10, :o2, 14816119, 6
- tz.transition 2049, 4, :o1, 14817211, 6
- tz.transition 2049, 10, :o2, 14818303, 6
- tz.transition 2050, 4, :o1, 14819395, 6
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Perth.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Perth.rb
deleted file mode 100644
index d9e66f14a8..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Perth.rb
+++ /dev/null
@@ -1,37 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Australia
- module Perth
- include TimezoneDefinition
-
- timezone 'Australia/Perth' do |tz|
- tz.offset :o0, 27804, 0, :LMT
- tz.offset :o1, 28800, 0, :WST
- tz.offset :o2, 28800, 3600, :WST
-
- tz.transition 1895, 11, :o1, 17377402883, 7200
- tz.transition 1916, 12, :o2, 3486570001, 1440
- tz.transition 1917, 3, :o1, 58111493, 24
- tz.transition 1941, 12, :o2, 9721441, 4
- tz.transition 1942, 3, :o1, 58330733, 24
- tz.transition 1942, 9, :o2, 9722517, 4
- tz.transition 1943, 3, :o1, 58339469, 24
- tz.transition 1974, 10, :o2, 152042400
- tz.transition 1975, 3, :o1, 162928800
- tz.transition 1983, 10, :o2, 436298400
- tz.transition 1984, 3, :o1, 447184800
- tz.transition 1991, 11, :o2, 690314400
- tz.transition 1992, 2, :o1, 699386400
- tz.transition 2006, 12, :o2, 1165082400
- tz.transition 2007, 3, :o1, 1174759200
- tz.transition 2007, 10, :o2, 1193508000
- tz.transition 2008, 3, :o1, 1206813600
- tz.transition 2008, 10, :o2, 1224957600
- tz.transition 2009, 3, :o1, 1238263200
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Sydney.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Sydney.rb
deleted file mode 100644
index 9062bd7c3c..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Australia/Sydney.rb
+++ /dev/null
@@ -1,185 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Australia
- module Sydney
- include TimezoneDefinition
-
- timezone 'Australia/Sydney' do |tz|
- tz.offset :o0, 36292, 0, :LMT
- tz.offset :o1, 36000, 0, :EST
- tz.offset :o2, 36000, 3600, :EST
-
- tz.transition 1895, 1, :o1, 52125661727, 21600
- tz.transition 1916, 12, :o2, 3486569881, 1440
- tz.transition 1917, 3, :o1, 19370497, 8
- tz.transition 1941, 12, :o2, 14582161, 6
- tz.transition 1942, 3, :o1, 19443577, 8
- tz.transition 1942, 9, :o2, 14583775, 6
- tz.transition 1943, 3, :o1, 19446489, 8
- tz.transition 1943, 10, :o2, 14586001, 6
- tz.transition 1944, 3, :o1, 19449401, 8
- tz.transition 1971, 10, :o2, 57686400
- tz.transition 1972, 2, :o1, 67968000
- tz.transition 1972, 10, :o2, 89136000
- tz.transition 1973, 3, :o1, 100022400
- tz.transition 1973, 10, :o2, 120585600
- tz.transition 1974, 3, :o1, 131472000
- tz.transition 1974, 10, :o2, 152035200
- tz.transition 1975, 3, :o1, 162921600
- tz.transition 1975, 10, :o2, 183484800
- tz.transition 1976, 3, :o1, 194976000
- tz.transition 1976, 10, :o2, 215539200
- tz.transition 1977, 3, :o1, 226425600
- tz.transition 1977, 10, :o2, 246988800
- tz.transition 1978, 3, :o1, 257875200
- tz.transition 1978, 10, :o2, 278438400
- tz.transition 1979, 3, :o1, 289324800
- tz.transition 1979, 10, :o2, 309888000
- tz.transition 1980, 3, :o1, 320774400
- tz.transition 1980, 10, :o2, 341337600
- tz.transition 1981, 2, :o1, 352224000
- tz.transition 1981, 10, :o2, 372787200
- tz.transition 1982, 4, :o1, 386697600
- tz.transition 1982, 10, :o2, 404841600
- tz.transition 1983, 3, :o1, 415728000
- tz.transition 1983, 10, :o2, 436291200
- tz.transition 1984, 3, :o1, 447177600
- tz.transition 1984, 10, :o2, 467740800
- tz.transition 1985, 3, :o1, 478627200
- tz.transition 1985, 10, :o2, 499190400
- tz.transition 1986, 3, :o1, 511286400
- tz.transition 1986, 10, :o2, 530035200
- tz.transition 1987, 3, :o1, 542736000
- tz.transition 1987, 10, :o2, 562089600
- tz.transition 1988, 3, :o1, 574790400
- tz.transition 1988, 10, :o2, 594144000
- tz.transition 1989, 3, :o1, 606240000
- tz.transition 1989, 10, :o2, 625593600
- tz.transition 1990, 3, :o1, 636480000
- tz.transition 1990, 10, :o2, 657043200
- tz.transition 1991, 3, :o1, 667929600
- tz.transition 1991, 10, :o2, 688492800
- tz.transition 1992, 2, :o1, 699379200
- tz.transition 1992, 10, :o2, 719942400
- tz.transition 1993, 3, :o1, 731433600
- tz.transition 1993, 10, :o2, 751996800
- tz.transition 1994, 3, :o1, 762883200
- tz.transition 1994, 10, :o2, 783446400
- tz.transition 1995, 3, :o1, 794332800
- tz.transition 1995, 10, :o2, 814896000
- tz.transition 1996, 3, :o1, 828201600
- tz.transition 1996, 10, :o2, 846345600
- tz.transition 1997, 3, :o1, 859651200
- tz.transition 1997, 10, :o2, 877795200
- tz.transition 1998, 3, :o1, 891100800
- tz.transition 1998, 10, :o2, 909244800
- tz.transition 1999, 3, :o1, 922550400
- tz.transition 1999, 10, :o2, 941299200
- tz.transition 2000, 3, :o1, 954000000
- tz.transition 2000, 8, :o2, 967305600
- tz.transition 2001, 3, :o1, 985449600
- tz.transition 2001, 10, :o2, 1004198400
- tz.transition 2002, 3, :o1, 1017504000
- tz.transition 2002, 10, :o2, 1035648000
- tz.transition 2003, 3, :o1, 1048953600
- tz.transition 2003, 10, :o2, 1067097600
- tz.transition 2004, 3, :o1, 1080403200
- tz.transition 2004, 10, :o2, 1099152000
- tz.transition 2005, 3, :o1, 1111852800
- tz.transition 2005, 10, :o2, 1130601600
- tz.transition 2006, 4, :o1, 1143907200
- tz.transition 2006, 10, :o2, 1162051200
- tz.transition 2007, 3, :o1, 1174752000
- tz.transition 2007, 10, :o2, 1193500800
- tz.transition 2008, 4, :o1, 1207411200
- tz.transition 2008, 10, :o2, 1223136000
- tz.transition 2009, 4, :o1, 1238860800
- tz.transition 2009, 10, :o2, 1254585600
- tz.transition 2010, 4, :o1, 1270310400
- tz.transition 2010, 10, :o2, 1286035200
- tz.transition 2011, 4, :o1, 1301760000
- tz.transition 2011, 10, :o2, 1317484800
- tz.transition 2012, 3, :o1, 1333209600
- tz.transition 2012, 10, :o2, 1349539200
- tz.transition 2013, 4, :o1, 1365264000
- tz.transition 2013, 10, :o2, 1380988800
- tz.transition 2014, 4, :o1, 1396713600
- tz.transition 2014, 10, :o2, 1412438400
- tz.transition 2015, 4, :o1, 1428163200
- tz.transition 2015, 10, :o2, 1443888000
- tz.transition 2016, 4, :o1, 1459612800
- tz.transition 2016, 10, :o2, 1475337600
- tz.transition 2017, 4, :o1, 1491062400
- tz.transition 2017, 9, :o2, 1506787200
- tz.transition 2018, 3, :o1, 1522512000
- tz.transition 2018, 10, :o2, 1538841600
- tz.transition 2019, 4, :o1, 1554566400
- tz.transition 2019, 10, :o2, 1570291200
- tz.transition 2020, 4, :o1, 1586016000
- tz.transition 2020, 10, :o2, 1601740800
- tz.transition 2021, 4, :o1, 1617465600
- tz.transition 2021, 10, :o2, 1633190400
- tz.transition 2022, 4, :o1, 1648915200
- tz.transition 2022, 10, :o2, 1664640000
- tz.transition 2023, 4, :o1, 1680364800
- tz.transition 2023, 9, :o2, 1696089600
- tz.transition 2024, 4, :o1, 1712419200
- tz.transition 2024, 10, :o2, 1728144000
- tz.transition 2025, 4, :o1, 1743868800
- tz.transition 2025, 10, :o2, 1759593600
- tz.transition 2026, 4, :o1, 1775318400
- tz.transition 2026, 10, :o2, 1791043200
- tz.transition 2027, 4, :o1, 1806768000
- tz.transition 2027, 10, :o2, 1822492800
- tz.transition 2028, 4, :o1, 1838217600
- tz.transition 2028, 9, :o2, 1853942400
- tz.transition 2029, 3, :o1, 1869667200
- tz.transition 2029, 10, :o2, 1885996800
- tz.transition 2030, 4, :o1, 1901721600
- tz.transition 2030, 10, :o2, 1917446400
- tz.transition 2031, 4, :o1, 1933171200
- tz.transition 2031, 10, :o2, 1948896000
- tz.transition 2032, 4, :o1, 1964620800
- tz.transition 2032, 10, :o2, 1980345600
- tz.transition 2033, 4, :o1, 1996070400
- tz.transition 2033, 10, :o2, 2011795200
- tz.transition 2034, 4, :o1, 2027520000
- tz.transition 2034, 9, :o2, 2043244800
- tz.transition 2035, 3, :o1, 2058969600
- tz.transition 2035, 10, :o2, 2075299200
- tz.transition 2036, 4, :o1, 2091024000
- tz.transition 2036, 10, :o2, 2106748800
- tz.transition 2037, 4, :o1, 2122473600
- tz.transition 2037, 10, :o2, 2138198400
- tz.transition 2038, 4, :o1, 14793103, 6
- tz.transition 2038, 10, :o2, 14794195, 6
- tz.transition 2039, 4, :o1, 14795287, 6
- tz.transition 2039, 10, :o2, 14796379, 6
- tz.transition 2040, 3, :o1, 14797471, 6
- tz.transition 2040, 10, :o2, 14798605, 6
- tz.transition 2041, 4, :o1, 14799697, 6
- tz.transition 2041, 10, :o2, 14800789, 6
- tz.transition 2042, 4, :o1, 14801881, 6
- tz.transition 2042, 10, :o2, 14802973, 6
- tz.transition 2043, 4, :o1, 14804065, 6
- tz.transition 2043, 10, :o2, 14805157, 6
- tz.transition 2044, 4, :o1, 14806249, 6
- tz.transition 2044, 10, :o2, 14807341, 6
- tz.transition 2045, 4, :o1, 14808433, 6
- tz.transition 2045, 9, :o2, 14809525, 6
- tz.transition 2046, 3, :o1, 14810617, 6
- tz.transition 2046, 10, :o2, 14811751, 6
- tz.transition 2047, 4, :o1, 14812843, 6
- tz.transition 2047, 10, :o2, 14813935, 6
- tz.transition 2048, 4, :o1, 14815027, 6
- tz.transition 2048, 10, :o2, 14816119, 6
- tz.transition 2049, 4, :o1, 14817211, 6
- tz.transition 2049, 10, :o2, 14818303, 6
- tz.transition 2050, 4, :o1, 14819395, 6
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Etc/UTC.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Etc/UTC.rb
deleted file mode 100644
index 28b2c6a04c..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Etc/UTC.rb
+++ /dev/null
@@ -1,16 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Etc
- module UTC
- include TimezoneDefinition
-
- timezone 'Etc/UTC' do |tz|
- tz.offset :o0, 0, 0, :UTC
-
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Amsterdam.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Amsterdam.rb
deleted file mode 100644
index 2d0c95c4bc..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Amsterdam.rb
+++ /dev/null
@@ -1,228 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Amsterdam
- include TimezoneDefinition
-
- timezone 'Europe/Amsterdam' do |tz|
- tz.offset :o0, 1172, 0, :LMT
- tz.offset :o1, 1172, 0, :AMT
- tz.offset :o2, 1172, 3600, :NST
- tz.offset :o3, 1200, 3600, :NEST
- tz.offset :o4, 1200, 0, :NET
- tz.offset :o5, 3600, 3600, :CEST
- tz.offset :o6, 3600, 0, :CET
-
- tz.transition 1834, 12, :o1, 51651636907, 21600
- tz.transition 1916, 4, :o2, 52293264907, 21600
- tz.transition 1916, 9, :o1, 52296568807, 21600
- tz.transition 1917, 4, :o2, 52300826707, 21600
- tz.transition 1917, 9, :o1, 52304153107, 21600
- tz.transition 1918, 4, :o2, 52308386707, 21600
- tz.transition 1918, 9, :o1, 52312317907, 21600
- tz.transition 1919, 4, :o2, 52316400307, 21600
- tz.transition 1919, 9, :o1, 52320180307, 21600
- tz.transition 1920, 4, :o2, 52324262707, 21600
- tz.transition 1920, 9, :o1, 52328042707, 21600
- tz.transition 1921, 4, :o2, 52332125107, 21600
- tz.transition 1921, 9, :o1, 52335905107, 21600
- tz.transition 1922, 3, :o2, 52339814707, 21600
- tz.transition 1922, 10, :o1, 52344048307, 21600
- tz.transition 1923, 6, :o2, 52349145907, 21600
- tz.transition 1923, 10, :o1, 52351910707, 21600
- tz.transition 1924, 3, :o2, 52355690707, 21600
- tz.transition 1924, 10, :o1, 52359773107, 21600
- tz.transition 1925, 6, :o2, 52365021907, 21600
- tz.transition 1925, 10, :o1, 52367635507, 21600
- tz.transition 1926, 5, :o2, 52372452307, 21600
- tz.transition 1926, 10, :o1, 52375497907, 21600
- tz.transition 1927, 5, :o2, 52380336307, 21600
- tz.transition 1927, 10, :o1, 52383360307, 21600
- tz.transition 1928, 5, :o2, 52388241907, 21600
- tz.transition 1928, 10, :o1, 52391373907, 21600
- tz.transition 1929, 5, :o2, 52396125907, 21600
- tz.transition 1929, 10, :o1, 52399236307, 21600
- tz.transition 1930, 5, :o2, 52404009907, 21600
- tz.transition 1930, 10, :o1, 52407098707, 21600
- tz.transition 1931, 5, :o2, 52411893907, 21600
- tz.transition 1931, 10, :o1, 52414961107, 21600
- tz.transition 1932, 5, :o2, 52419950707, 21600
- tz.transition 1932, 10, :o1, 52422823507, 21600
- tz.transition 1933, 5, :o2, 52427683507, 21600
- tz.transition 1933, 10, :o1, 52430837107, 21600
- tz.transition 1934, 5, :o2, 52435567507, 21600
- tz.transition 1934, 10, :o1, 52438699507, 21600
- tz.transition 1935, 5, :o2, 52443451507, 21600
- tz.transition 1935, 10, :o1, 52446561907, 21600
- tz.transition 1936, 5, :o2, 52451357107, 21600
- tz.transition 1936, 10, :o1, 52454424307, 21600
- tz.transition 1937, 5, :o2, 52459392307, 21600
- tz.transition 1937, 6, :o3, 52460253607, 21600
- tz.transition 1937, 10, :o4, 174874289, 72
- tz.transition 1938, 5, :o3, 174890417, 72
- tz.transition 1938, 10, :o4, 174900497, 72
- tz.transition 1939, 5, :o3, 174916697, 72
- tz.transition 1939, 10, :o4, 174927209, 72
- tz.transition 1940, 5, :o5, 174943115, 72
- tz.transition 1942, 11, :o6, 58335973, 24
- tz.transition 1943, 3, :o5, 58339501, 24
- tz.transition 1943, 10, :o6, 58344037, 24
- tz.transition 1944, 4, :o5, 58348405, 24
- tz.transition 1944, 10, :o6, 58352773, 24
- tz.transition 1945, 4, :o5, 58357141, 24
- tz.transition 1945, 9, :o6, 58361149, 24
- tz.transition 1977, 4, :o5, 228877200
- tz.transition 1977, 9, :o6, 243997200
- tz.transition 1978, 4, :o5, 260326800
- tz.transition 1978, 10, :o6, 276051600
- tz.transition 1979, 4, :o5, 291776400
- tz.transition 1979, 9, :o6, 307501200
- tz.transition 1980, 4, :o5, 323830800
- tz.transition 1980, 9, :o6, 338950800
- tz.transition 1981, 3, :o5, 354675600
- tz.transition 1981, 9, :o6, 370400400
- tz.transition 1982, 3, :o5, 386125200
- tz.transition 1982, 9, :o6, 401850000
- tz.transition 1983, 3, :o5, 417574800
- tz.transition 1983, 9, :o6, 433299600
- tz.transition 1984, 3, :o5, 449024400
- tz.transition 1984, 9, :o6, 465354000
- tz.transition 1985, 3, :o5, 481078800
- tz.transition 1985, 9, :o6, 496803600
- tz.transition 1986, 3, :o5, 512528400
- tz.transition 1986, 9, :o6, 528253200
- tz.transition 1987, 3, :o5, 543978000
- tz.transition 1987, 9, :o6, 559702800
- tz.transition 1988, 3, :o5, 575427600
- tz.transition 1988, 9, :o6, 591152400
- tz.transition 1989, 3, :o5, 606877200
- tz.transition 1989, 9, :o6, 622602000
- tz.transition 1990, 3, :o5, 638326800
- tz.transition 1990, 9, :o6, 654656400
- tz.transition 1991, 3, :o5, 670381200
- tz.transition 1991, 9, :o6, 686106000
- tz.transition 1992, 3, :o5, 701830800
- tz.transition 1992, 9, :o6, 717555600
- tz.transition 1993, 3, :o5, 733280400
- tz.transition 1993, 9, :o6, 749005200
- tz.transition 1994, 3, :o5, 764730000
- tz.transition 1994, 9, :o6, 780454800
- tz.transition 1995, 3, :o5, 796179600
- tz.transition 1995, 9, :o6, 811904400
- tz.transition 1996, 3, :o5, 828234000
- tz.transition 1996, 10, :o6, 846378000
- tz.transition 1997, 3, :o5, 859683600
- tz.transition 1997, 10, :o6, 877827600
- tz.transition 1998, 3, :o5, 891133200
- tz.transition 1998, 10, :o6, 909277200
- tz.transition 1999, 3, :o5, 922582800
- tz.transition 1999, 10, :o6, 941331600
- tz.transition 2000, 3, :o5, 954032400
- tz.transition 2000, 10, :o6, 972781200
- tz.transition 2001, 3, :o5, 985482000
- tz.transition 2001, 10, :o6, 1004230800
- tz.transition 2002, 3, :o5, 1017536400
- tz.transition 2002, 10, :o6, 1035680400
- tz.transition 2003, 3, :o5, 1048986000
- tz.transition 2003, 10, :o6, 1067130000
- tz.transition 2004, 3, :o5, 1080435600
- tz.transition 2004, 10, :o6, 1099184400
- tz.transition 2005, 3, :o5, 1111885200
- tz.transition 2005, 10, :o6, 1130634000
- tz.transition 2006, 3, :o5, 1143334800
- tz.transition 2006, 10, :o6, 1162083600
- tz.transition 2007, 3, :o5, 1174784400
- tz.transition 2007, 10, :o6, 1193533200
- tz.transition 2008, 3, :o5, 1206838800
- tz.transition 2008, 10, :o6, 1224982800
- tz.transition 2009, 3, :o5, 1238288400
- tz.transition 2009, 10, :o6, 1256432400
- tz.transition 2010, 3, :o5, 1269738000
- tz.transition 2010, 10, :o6, 1288486800
- tz.transition 2011, 3, :o5, 1301187600
- tz.transition 2011, 10, :o6, 1319936400
- tz.transition 2012, 3, :o5, 1332637200
- tz.transition 2012, 10, :o6, 1351386000
- tz.transition 2013, 3, :o5, 1364691600
- tz.transition 2013, 10, :o6, 1382835600
- tz.transition 2014, 3, :o5, 1396141200
- tz.transition 2014, 10, :o6, 1414285200
- tz.transition 2015, 3, :o5, 1427590800
- tz.transition 2015, 10, :o6, 1445734800
- tz.transition 2016, 3, :o5, 1459040400
- tz.transition 2016, 10, :o6, 1477789200
- tz.transition 2017, 3, :o5, 1490490000
- tz.transition 2017, 10, :o6, 1509238800
- tz.transition 2018, 3, :o5, 1521939600
- tz.transition 2018, 10, :o6, 1540688400
- tz.transition 2019, 3, :o5, 1553994000
- tz.transition 2019, 10, :o6, 1572138000
- tz.transition 2020, 3, :o5, 1585443600
- tz.transition 2020, 10, :o6, 1603587600
- tz.transition 2021, 3, :o5, 1616893200
- tz.transition 2021, 10, :o6, 1635642000
- tz.transition 2022, 3, :o5, 1648342800
- tz.transition 2022, 10, :o6, 1667091600
- tz.transition 2023, 3, :o5, 1679792400
- tz.transition 2023, 10, :o6, 1698541200
- tz.transition 2024, 3, :o5, 1711846800
- tz.transition 2024, 10, :o6, 1729990800
- tz.transition 2025, 3, :o5, 1743296400
- tz.transition 2025, 10, :o6, 1761440400
- tz.transition 2026, 3, :o5, 1774746000
- tz.transition 2026, 10, :o6, 1792890000
- tz.transition 2027, 3, :o5, 1806195600
- tz.transition 2027, 10, :o6, 1824944400
- tz.transition 2028, 3, :o5, 1837645200
- tz.transition 2028, 10, :o6, 1856394000
- tz.transition 2029, 3, :o5, 1869094800
- tz.transition 2029, 10, :o6, 1887843600
- tz.transition 2030, 3, :o5, 1901149200
- tz.transition 2030, 10, :o6, 1919293200
- tz.transition 2031, 3, :o5, 1932598800
- tz.transition 2031, 10, :o6, 1950742800
- tz.transition 2032, 3, :o5, 1964048400
- tz.transition 2032, 10, :o6, 1982797200
- tz.transition 2033, 3, :o5, 1995498000
- tz.transition 2033, 10, :o6, 2014246800
- tz.transition 2034, 3, :o5, 2026947600
- tz.transition 2034, 10, :o6, 2045696400
- tz.transition 2035, 3, :o5, 2058397200
- tz.transition 2035, 10, :o6, 2077146000
- tz.transition 2036, 3, :o5, 2090451600
- tz.transition 2036, 10, :o6, 2108595600
- tz.transition 2037, 3, :o5, 2121901200
- tz.transition 2037, 10, :o6, 2140045200
- tz.transition 2038, 3, :o5, 59172253, 24
- tz.transition 2038, 10, :o6, 59177461, 24
- tz.transition 2039, 3, :o5, 59180989, 24
- tz.transition 2039, 10, :o6, 59186197, 24
- tz.transition 2040, 3, :o5, 59189725, 24
- tz.transition 2040, 10, :o6, 59194933, 24
- tz.transition 2041, 3, :o5, 59198629, 24
- tz.transition 2041, 10, :o6, 59203669, 24
- tz.transition 2042, 3, :o5, 59207365, 24
- tz.transition 2042, 10, :o6, 59212405, 24
- tz.transition 2043, 3, :o5, 59216101, 24
- tz.transition 2043, 10, :o6, 59221141, 24
- tz.transition 2044, 3, :o5, 59224837, 24
- tz.transition 2044, 10, :o6, 59230045, 24
- tz.transition 2045, 3, :o5, 59233573, 24
- tz.transition 2045, 10, :o6, 59238781, 24
- tz.transition 2046, 3, :o5, 59242309, 24
- tz.transition 2046, 10, :o6, 59247517, 24
- tz.transition 2047, 3, :o5, 59251213, 24
- tz.transition 2047, 10, :o6, 59256253, 24
- tz.transition 2048, 3, :o5, 59259949, 24
- tz.transition 2048, 10, :o6, 59264989, 24
- tz.transition 2049, 3, :o5, 59268685, 24
- tz.transition 2049, 10, :o6, 59273893, 24
- tz.transition 2050, 3, :o5, 59277421, 24
- tz.transition 2050, 10, :o6, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Athens.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Athens.rb
deleted file mode 100644
index 4e21e535ca..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Athens.rb
+++ /dev/null
@@ -1,185 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Athens
- include TimezoneDefinition
-
- timezone 'Europe/Athens' do |tz|
- tz.offset :o0, 5692, 0, :LMT
- tz.offset :o1, 5692, 0, :AMT
- tz.offset :o2, 7200, 0, :EET
- tz.offset :o3, 7200, 3600, :EEST
- tz.offset :o4, 3600, 3600, :CEST
- tz.offset :o5, 3600, 0, :CET
-
- tz.transition 1895, 9, :o1, 52130529377, 21600
- tz.transition 1916, 7, :o2, 3268447787, 1350
- tz.transition 1932, 7, :o3, 29122745, 12
- tz.transition 1932, 8, :o2, 19415611, 8
- tz.transition 1941, 4, :o3, 29161097, 12
- tz.transition 1941, 4, :o4, 19440915, 8
- tz.transition 1942, 11, :o5, 58335973, 24
- tz.transition 1943, 3, :o4, 58339523, 24
- tz.transition 1943, 10, :o5, 29172017, 12
- tz.transition 1944, 4, :o2, 58348427, 24
- tz.transition 1952, 6, :o3, 29210333, 12
- tz.transition 1952, 11, :o2, 19474547, 8
- tz.transition 1975, 4, :o3, 166485600
- tz.transition 1975, 11, :o2, 186184800
- tz.transition 1976, 4, :o3, 198028800
- tz.transition 1976, 10, :o2, 213753600
- tz.transition 1977, 4, :o3, 228873600
- tz.transition 1977, 9, :o2, 244080000
- tz.transition 1978, 4, :o3, 260323200
- tz.transition 1978, 9, :o2, 275446800
- tz.transition 1979, 4, :o3, 291798000
- tz.transition 1979, 9, :o2, 307407600
- tz.transition 1980, 3, :o3, 323388000
- tz.transition 1980, 9, :o2, 338936400
- tz.transition 1981, 3, :o3, 354675600
- tz.transition 1981, 9, :o2, 370400400
- tz.transition 1982, 3, :o3, 386125200
- tz.transition 1982, 9, :o2, 401850000
- tz.transition 1983, 3, :o3, 417574800
- tz.transition 1983, 9, :o2, 433299600
- tz.transition 1984, 3, :o3, 449024400
- tz.transition 1984, 9, :o2, 465354000
- tz.transition 1985, 3, :o3, 481078800
- tz.transition 1985, 9, :o2, 496803600
- tz.transition 1986, 3, :o3, 512528400
- tz.transition 1986, 9, :o2, 528253200
- tz.transition 1987, 3, :o3, 543978000
- tz.transition 1987, 9, :o2, 559702800
- tz.transition 1988, 3, :o3, 575427600
- tz.transition 1988, 9, :o2, 591152400
- tz.transition 1989, 3, :o3, 606877200
- tz.transition 1989, 9, :o2, 622602000
- tz.transition 1990, 3, :o3, 638326800
- tz.transition 1990, 9, :o2, 654656400
- tz.transition 1991, 3, :o3, 670381200
- tz.transition 1991, 9, :o2, 686106000
- tz.transition 1992, 3, :o3, 701830800
- tz.transition 1992, 9, :o2, 717555600
- tz.transition 1993, 3, :o3, 733280400
- tz.transition 1993, 9, :o2, 749005200
- tz.transition 1994, 3, :o3, 764730000
- tz.transition 1994, 9, :o2, 780454800
- tz.transition 1995, 3, :o3, 796179600
- tz.transition 1995, 9, :o2, 811904400
- tz.transition 1996, 3, :o3, 828234000
- tz.transition 1996, 10, :o2, 846378000
- tz.transition 1997, 3, :o3, 859683600
- tz.transition 1997, 10, :o2, 877827600
- tz.transition 1998, 3, :o3, 891133200
- tz.transition 1998, 10, :o2, 909277200
- tz.transition 1999, 3, :o3, 922582800
- tz.transition 1999, 10, :o2, 941331600
- tz.transition 2000, 3, :o3, 954032400
- tz.transition 2000, 10, :o2, 972781200
- tz.transition 2001, 3, :o3, 985482000
- tz.transition 2001, 10, :o2, 1004230800
- tz.transition 2002, 3, :o3, 1017536400
- tz.transition 2002, 10, :o2, 1035680400
- tz.transition 2003, 3, :o3, 1048986000
- tz.transition 2003, 10, :o2, 1067130000
- tz.transition 2004, 3, :o3, 1080435600
- tz.transition 2004, 10, :o2, 1099184400
- tz.transition 2005, 3, :o3, 1111885200
- tz.transition 2005, 10, :o2, 1130634000
- tz.transition 2006, 3, :o3, 1143334800
- tz.transition 2006, 10, :o2, 1162083600
- tz.transition 2007, 3, :o3, 1174784400
- tz.transition 2007, 10, :o2, 1193533200
- tz.transition 2008, 3, :o3, 1206838800
- tz.transition 2008, 10, :o2, 1224982800
- tz.transition 2009, 3, :o3, 1238288400
- tz.transition 2009, 10, :o2, 1256432400
- tz.transition 2010, 3, :o3, 1269738000
- tz.transition 2010, 10, :o2, 1288486800
- tz.transition 2011, 3, :o3, 1301187600
- tz.transition 2011, 10, :o2, 1319936400
- tz.transition 2012, 3, :o3, 1332637200
- tz.transition 2012, 10, :o2, 1351386000
- tz.transition 2013, 3, :o3, 1364691600
- tz.transition 2013, 10, :o2, 1382835600
- tz.transition 2014, 3, :o3, 1396141200
- tz.transition 2014, 10, :o2, 1414285200
- tz.transition 2015, 3, :o3, 1427590800
- tz.transition 2015, 10, :o2, 1445734800
- tz.transition 2016, 3, :o3, 1459040400
- tz.transition 2016, 10, :o2, 1477789200
- tz.transition 2017, 3, :o3, 1490490000
- tz.transition 2017, 10, :o2, 1509238800
- tz.transition 2018, 3, :o3, 1521939600
- tz.transition 2018, 10, :o2, 1540688400
- tz.transition 2019, 3, :o3, 1553994000
- tz.transition 2019, 10, :o2, 1572138000
- tz.transition 2020, 3, :o3, 1585443600
- tz.transition 2020, 10, :o2, 1603587600
- tz.transition 2021, 3, :o3, 1616893200
- tz.transition 2021, 10, :o2, 1635642000
- tz.transition 2022, 3, :o3, 1648342800
- tz.transition 2022, 10, :o2, 1667091600
- tz.transition 2023, 3, :o3, 1679792400
- tz.transition 2023, 10, :o2, 1698541200
- tz.transition 2024, 3, :o3, 1711846800
- tz.transition 2024, 10, :o2, 1729990800
- tz.transition 2025, 3, :o3, 1743296400
- tz.transition 2025, 10, :o2, 1761440400
- tz.transition 2026, 3, :o3, 1774746000
- tz.transition 2026, 10, :o2, 1792890000
- tz.transition 2027, 3, :o3, 1806195600
- tz.transition 2027, 10, :o2, 1824944400
- tz.transition 2028, 3, :o3, 1837645200
- tz.transition 2028, 10, :o2, 1856394000
- tz.transition 2029, 3, :o3, 1869094800
- tz.transition 2029, 10, :o2, 1887843600
- tz.transition 2030, 3, :o3, 1901149200
- tz.transition 2030, 10, :o2, 1919293200
- tz.transition 2031, 3, :o3, 1932598800
- tz.transition 2031, 10, :o2, 1950742800
- tz.transition 2032, 3, :o3, 1964048400
- tz.transition 2032, 10, :o2, 1982797200
- tz.transition 2033, 3, :o3, 1995498000
- tz.transition 2033, 10, :o2, 2014246800
- tz.transition 2034, 3, :o3, 2026947600
- tz.transition 2034, 10, :o2, 2045696400
- tz.transition 2035, 3, :o3, 2058397200
- tz.transition 2035, 10, :o2, 2077146000
- tz.transition 2036, 3, :o3, 2090451600
- tz.transition 2036, 10, :o2, 2108595600
- tz.transition 2037, 3, :o3, 2121901200
- tz.transition 2037, 10, :o2, 2140045200
- tz.transition 2038, 3, :o3, 59172253, 24
- tz.transition 2038, 10, :o2, 59177461, 24
- tz.transition 2039, 3, :o3, 59180989, 24
- tz.transition 2039, 10, :o2, 59186197, 24
- tz.transition 2040, 3, :o3, 59189725, 24
- tz.transition 2040, 10, :o2, 59194933, 24
- tz.transition 2041, 3, :o3, 59198629, 24
- tz.transition 2041, 10, :o2, 59203669, 24
- tz.transition 2042, 3, :o3, 59207365, 24
- tz.transition 2042, 10, :o2, 59212405, 24
- tz.transition 2043, 3, :o3, 59216101, 24
- tz.transition 2043, 10, :o2, 59221141, 24
- tz.transition 2044, 3, :o3, 59224837, 24
- tz.transition 2044, 10, :o2, 59230045, 24
- tz.transition 2045, 3, :o3, 59233573, 24
- tz.transition 2045, 10, :o2, 59238781, 24
- tz.transition 2046, 3, :o3, 59242309, 24
- tz.transition 2046, 10, :o2, 59247517, 24
- tz.transition 2047, 3, :o3, 59251213, 24
- tz.transition 2047, 10, :o2, 59256253, 24
- tz.transition 2048, 3, :o3, 59259949, 24
- tz.transition 2048, 10, :o2, 59264989, 24
- tz.transition 2049, 3, :o3, 59268685, 24
- tz.transition 2049, 10, :o2, 59273893, 24
- tz.transition 2050, 3, :o3, 59277421, 24
- tz.transition 2050, 10, :o2, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Belgrade.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Belgrade.rb
deleted file mode 100644
index 4dbd893d75..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Belgrade.rb
+++ /dev/null
@@ -1,163 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Belgrade
- include TimezoneDefinition
-
- timezone 'Europe/Belgrade' do |tz|
- tz.offset :o0, 4920, 0, :LMT
- tz.offset :o1, 3600, 0, :CET
- tz.offset :o2, 3600, 3600, :CEST
-
- tz.transition 1883, 12, :o1, 1734607039, 720
- tz.transition 1941, 4, :o2, 29161241, 12
- tz.transition 1942, 11, :o1, 58335973, 24
- tz.transition 1943, 3, :o2, 58339501, 24
- tz.transition 1943, 10, :o1, 58344037, 24
- tz.transition 1944, 4, :o2, 58348405, 24
- tz.transition 1944, 10, :o1, 58352773, 24
- tz.transition 1945, 5, :o2, 58358005, 24
- tz.transition 1945, 9, :o1, 58361149, 24
- tz.transition 1983, 3, :o2, 417574800
- tz.transition 1983, 9, :o1, 433299600
- tz.transition 1984, 3, :o2, 449024400
- tz.transition 1984, 9, :o1, 465354000
- tz.transition 1985, 3, :o2, 481078800
- tz.transition 1985, 9, :o1, 496803600
- tz.transition 1986, 3, :o2, 512528400
- tz.transition 1986, 9, :o1, 528253200
- tz.transition 1987, 3, :o2, 543978000
- tz.transition 1987, 9, :o1, 559702800
- tz.transition 1988, 3, :o2, 575427600
- tz.transition 1988, 9, :o1, 591152400
- tz.transition 1989, 3, :o2, 606877200
- tz.transition 1989, 9, :o1, 622602000
- tz.transition 1990, 3, :o2, 638326800
- tz.transition 1990, 9, :o1, 654656400
- tz.transition 1991, 3, :o2, 670381200
- tz.transition 1991, 9, :o1, 686106000
- tz.transition 1992, 3, :o2, 701830800
- tz.transition 1992, 9, :o1, 717555600
- tz.transition 1993, 3, :o2, 733280400
- tz.transition 1993, 9, :o1, 749005200
- tz.transition 1994, 3, :o2, 764730000
- tz.transition 1994, 9, :o1, 780454800
- tz.transition 1995, 3, :o2, 796179600
- tz.transition 1995, 9, :o1, 811904400
- tz.transition 1996, 3, :o2, 828234000
- tz.transition 1996, 10, :o1, 846378000
- tz.transition 1997, 3, :o2, 859683600
- tz.transition 1997, 10, :o1, 877827600
- tz.transition 1998, 3, :o2, 891133200
- tz.transition 1998, 10, :o1, 909277200
- tz.transition 1999, 3, :o2, 922582800
- tz.transition 1999, 10, :o1, 941331600
- tz.transition 2000, 3, :o2, 954032400
- tz.transition 2000, 10, :o1, 972781200
- tz.transition 2001, 3, :o2, 985482000
- tz.transition 2001, 10, :o1, 1004230800
- tz.transition 2002, 3, :o2, 1017536400
- tz.transition 2002, 10, :o1, 1035680400
- tz.transition 2003, 3, :o2, 1048986000
- tz.transition 2003, 10, :o1, 1067130000
- tz.transition 2004, 3, :o2, 1080435600
- tz.transition 2004, 10, :o1, 1099184400
- tz.transition 2005, 3, :o2, 1111885200
- tz.transition 2005, 10, :o1, 1130634000
- tz.transition 2006, 3, :o2, 1143334800
- tz.transition 2006, 10, :o1, 1162083600
- tz.transition 2007, 3, :o2, 1174784400
- tz.transition 2007, 10, :o1, 1193533200
- tz.transition 2008, 3, :o2, 1206838800
- tz.transition 2008, 10, :o1, 1224982800
- tz.transition 2009, 3, :o2, 1238288400
- tz.transition 2009, 10, :o1, 1256432400
- tz.transition 2010, 3, :o2, 1269738000
- tz.transition 2010, 10, :o1, 1288486800
- tz.transition 2011, 3, :o2, 1301187600
- tz.transition 2011, 10, :o1, 1319936400
- tz.transition 2012, 3, :o2, 1332637200
- tz.transition 2012, 10, :o1, 1351386000
- tz.transition 2013, 3, :o2, 1364691600
- tz.transition 2013, 10, :o1, 1382835600
- tz.transition 2014, 3, :o2, 1396141200
- tz.transition 2014, 10, :o1, 1414285200
- tz.transition 2015, 3, :o2, 1427590800
- tz.transition 2015, 10, :o1, 1445734800
- tz.transition 2016, 3, :o2, 1459040400
- tz.transition 2016, 10, :o1, 1477789200
- tz.transition 2017, 3, :o2, 1490490000
- tz.transition 2017, 10, :o1, 1509238800
- tz.transition 2018, 3, :o2, 1521939600
- tz.transition 2018, 10, :o1, 1540688400
- tz.transition 2019, 3, :o2, 1553994000
- tz.transition 2019, 10, :o1, 1572138000
- tz.transition 2020, 3, :o2, 1585443600
- tz.transition 2020, 10, :o1, 1603587600
- tz.transition 2021, 3, :o2, 1616893200
- tz.transition 2021, 10, :o1, 1635642000
- tz.transition 2022, 3, :o2, 1648342800
- tz.transition 2022, 10, :o1, 1667091600
- tz.transition 2023, 3, :o2, 1679792400
- tz.transition 2023, 10, :o1, 1698541200
- tz.transition 2024, 3, :o2, 1711846800
- tz.transition 2024, 10, :o1, 1729990800
- tz.transition 2025, 3, :o2, 1743296400
- tz.transition 2025, 10, :o1, 1761440400
- tz.transition 2026, 3, :o2, 1774746000
- tz.transition 2026, 10, :o1, 1792890000
- tz.transition 2027, 3, :o2, 1806195600
- tz.transition 2027, 10, :o1, 1824944400
- tz.transition 2028, 3, :o2, 1837645200
- tz.transition 2028, 10, :o1, 1856394000
- tz.transition 2029, 3, :o2, 1869094800
- tz.transition 2029, 10, :o1, 1887843600
- tz.transition 2030, 3, :o2, 1901149200
- tz.transition 2030, 10, :o1, 1919293200
- tz.transition 2031, 3, :o2, 1932598800
- tz.transition 2031, 10, :o1, 1950742800
- tz.transition 2032, 3, :o2, 1964048400
- tz.transition 2032, 10, :o1, 1982797200
- tz.transition 2033, 3, :o2, 1995498000
- tz.transition 2033, 10, :o1, 2014246800
- tz.transition 2034, 3, :o2, 2026947600
- tz.transition 2034, 10, :o1, 2045696400
- tz.transition 2035, 3, :o2, 2058397200
- tz.transition 2035, 10, :o1, 2077146000
- tz.transition 2036, 3, :o2, 2090451600
- tz.transition 2036, 10, :o1, 2108595600
- tz.transition 2037, 3, :o2, 2121901200
- tz.transition 2037, 10, :o1, 2140045200
- tz.transition 2038, 3, :o2, 59172253, 24
- tz.transition 2038, 10, :o1, 59177461, 24
- tz.transition 2039, 3, :o2, 59180989, 24
- tz.transition 2039, 10, :o1, 59186197, 24
- tz.transition 2040, 3, :o2, 59189725, 24
- tz.transition 2040, 10, :o1, 59194933, 24
- tz.transition 2041, 3, :o2, 59198629, 24
- tz.transition 2041, 10, :o1, 59203669, 24
- tz.transition 2042, 3, :o2, 59207365, 24
- tz.transition 2042, 10, :o1, 59212405, 24
- tz.transition 2043, 3, :o2, 59216101, 24
- tz.transition 2043, 10, :o1, 59221141, 24
- tz.transition 2044, 3, :o2, 59224837, 24
- tz.transition 2044, 10, :o1, 59230045, 24
- tz.transition 2045, 3, :o2, 59233573, 24
- tz.transition 2045, 10, :o1, 59238781, 24
- tz.transition 2046, 3, :o2, 59242309, 24
- tz.transition 2046, 10, :o1, 59247517, 24
- tz.transition 2047, 3, :o2, 59251213, 24
- tz.transition 2047, 10, :o1, 59256253, 24
- tz.transition 2048, 3, :o2, 59259949, 24
- tz.transition 2048, 10, :o1, 59264989, 24
- tz.transition 2049, 3, :o2, 59268685, 24
- tz.transition 2049, 10, :o1, 59273893, 24
- tz.transition 2050, 3, :o2, 59277421, 24
- tz.transition 2050, 10, :o1, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Berlin.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Berlin.rb
deleted file mode 100644
index 721054236c..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Berlin.rb
+++ /dev/null
@@ -1,188 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Berlin
- include TimezoneDefinition
-
- timezone 'Europe/Berlin' do |tz|
- tz.offset :o0, 3208, 0, :LMT
- tz.offset :o1, 3600, 0, :CET
- tz.offset :o2, 3600, 3600, :CEST
- tz.offset :o3, 3600, 7200, :CEMT
-
- tz.transition 1893, 3, :o1, 26055588199, 10800
- tz.transition 1916, 4, :o2, 29051813, 12
- tz.transition 1916, 9, :o1, 58107299, 24
- tz.transition 1917, 4, :o2, 58112029, 24
- tz.transition 1917, 9, :o1, 58115725, 24
- tz.transition 1918, 4, :o2, 58120765, 24
- tz.transition 1918, 9, :o1, 58124461, 24
- tz.transition 1940, 4, :o2, 58313293, 24
- tz.transition 1942, 11, :o1, 58335973, 24
- tz.transition 1943, 3, :o2, 58339501, 24
- tz.transition 1943, 10, :o1, 58344037, 24
- tz.transition 1944, 4, :o2, 58348405, 24
- tz.transition 1944, 10, :o1, 58352773, 24
- tz.transition 1945, 4, :o2, 58357141, 24
- tz.transition 1945, 5, :o3, 4863199, 2
- tz.transition 1945, 9, :o2, 4863445, 2
- tz.transition 1945, 11, :o1, 58362661, 24
- tz.transition 1946, 4, :o2, 58366189, 24
- tz.transition 1946, 10, :o1, 58370413, 24
- tz.transition 1947, 4, :o2, 29187379, 12
- tz.transition 1947, 5, :o3, 58375597, 24
- tz.transition 1947, 6, :o2, 4864731, 2
- tz.transition 1947, 10, :o1, 58379125, 24
- tz.transition 1948, 4, :o2, 58383829, 24
- tz.transition 1948, 10, :o1, 58387861, 24
- tz.transition 1949, 4, :o2, 58392397, 24
- tz.transition 1949, 10, :o1, 58396597, 24
- tz.transition 1980, 4, :o2, 323830800
- tz.transition 1980, 9, :o1, 338950800
- tz.transition 1981, 3, :o2, 354675600
- tz.transition 1981, 9, :o1, 370400400
- tz.transition 1982, 3, :o2, 386125200
- tz.transition 1982, 9, :o1, 401850000
- tz.transition 1983, 3, :o2, 417574800
- tz.transition 1983, 9, :o1, 433299600
- tz.transition 1984, 3, :o2, 449024400
- tz.transition 1984, 9, :o1, 465354000
- tz.transition 1985, 3, :o2, 481078800
- tz.transition 1985, 9, :o1, 496803600
- tz.transition 1986, 3, :o2, 512528400
- tz.transition 1986, 9, :o1, 528253200
- tz.transition 1987, 3, :o2, 543978000
- tz.transition 1987, 9, :o1, 559702800
- tz.transition 1988, 3, :o2, 575427600
- tz.transition 1988, 9, :o1, 591152400
- tz.transition 1989, 3, :o2, 606877200
- tz.transition 1989, 9, :o1, 622602000
- tz.transition 1990, 3, :o2, 638326800
- tz.transition 1990, 9, :o1, 654656400
- tz.transition 1991, 3, :o2, 670381200
- tz.transition 1991, 9, :o1, 686106000
- tz.transition 1992, 3, :o2, 701830800
- tz.transition 1992, 9, :o1, 717555600
- tz.transition 1993, 3, :o2, 733280400
- tz.transition 1993, 9, :o1, 749005200
- tz.transition 1994, 3, :o2, 764730000
- tz.transition 1994, 9, :o1, 780454800
- tz.transition 1995, 3, :o2, 796179600
- tz.transition 1995, 9, :o1, 811904400
- tz.transition 1996, 3, :o2, 828234000
- tz.transition 1996, 10, :o1, 846378000
- tz.transition 1997, 3, :o2, 859683600
- tz.transition 1997, 10, :o1, 877827600
- tz.transition 1998, 3, :o2, 891133200
- tz.transition 1998, 10, :o1, 909277200
- tz.transition 1999, 3, :o2, 922582800
- tz.transition 1999, 10, :o1, 941331600
- tz.transition 2000, 3, :o2, 954032400
- tz.transition 2000, 10, :o1, 972781200
- tz.transition 2001, 3, :o2, 985482000
- tz.transition 2001, 10, :o1, 1004230800
- tz.transition 2002, 3, :o2, 1017536400
- tz.transition 2002, 10, :o1, 1035680400
- tz.transition 2003, 3, :o2, 1048986000
- tz.transition 2003, 10, :o1, 1067130000
- tz.transition 2004, 3, :o2, 1080435600
- tz.transition 2004, 10, :o1, 1099184400
- tz.transition 2005, 3, :o2, 1111885200
- tz.transition 2005, 10, :o1, 1130634000
- tz.transition 2006, 3, :o2, 1143334800
- tz.transition 2006, 10, :o1, 1162083600
- tz.transition 2007, 3, :o2, 1174784400
- tz.transition 2007, 10, :o1, 1193533200
- tz.transition 2008, 3, :o2, 1206838800
- tz.transition 2008, 10, :o1, 1224982800
- tz.transition 2009, 3, :o2, 1238288400
- tz.transition 2009, 10, :o1, 1256432400
- tz.transition 2010, 3, :o2, 1269738000
- tz.transition 2010, 10, :o1, 1288486800
- tz.transition 2011, 3, :o2, 1301187600
- tz.transition 2011, 10, :o1, 1319936400
- tz.transition 2012, 3, :o2, 1332637200
- tz.transition 2012, 10, :o1, 1351386000
- tz.transition 2013, 3, :o2, 1364691600
- tz.transition 2013, 10, :o1, 1382835600
- tz.transition 2014, 3, :o2, 1396141200
- tz.transition 2014, 10, :o1, 1414285200
- tz.transition 2015, 3, :o2, 1427590800
- tz.transition 2015, 10, :o1, 1445734800
- tz.transition 2016, 3, :o2, 1459040400
- tz.transition 2016, 10, :o1, 1477789200
- tz.transition 2017, 3, :o2, 1490490000
- tz.transition 2017, 10, :o1, 1509238800
- tz.transition 2018, 3, :o2, 1521939600
- tz.transition 2018, 10, :o1, 1540688400
- tz.transition 2019, 3, :o2, 1553994000
- tz.transition 2019, 10, :o1, 1572138000
- tz.transition 2020, 3, :o2, 1585443600
- tz.transition 2020, 10, :o1, 1603587600
- tz.transition 2021, 3, :o2, 1616893200
- tz.transition 2021, 10, :o1, 1635642000
- tz.transition 2022, 3, :o2, 1648342800
- tz.transition 2022, 10, :o1, 1667091600
- tz.transition 2023, 3, :o2, 1679792400
- tz.transition 2023, 10, :o1, 1698541200
- tz.transition 2024, 3, :o2, 1711846800
- tz.transition 2024, 10, :o1, 1729990800
- tz.transition 2025, 3, :o2, 1743296400
- tz.transition 2025, 10, :o1, 1761440400
- tz.transition 2026, 3, :o2, 1774746000
- tz.transition 2026, 10, :o1, 1792890000
- tz.transition 2027, 3, :o2, 1806195600
- tz.transition 2027, 10, :o1, 1824944400
- tz.transition 2028, 3, :o2, 1837645200
- tz.transition 2028, 10, :o1, 1856394000
- tz.transition 2029, 3, :o2, 1869094800
- tz.transition 2029, 10, :o1, 1887843600
- tz.transition 2030, 3, :o2, 1901149200
- tz.transition 2030, 10, :o1, 1919293200
- tz.transition 2031, 3, :o2, 1932598800
- tz.transition 2031, 10, :o1, 1950742800
- tz.transition 2032, 3, :o2, 1964048400
- tz.transition 2032, 10, :o1, 1982797200
- tz.transition 2033, 3, :o2, 1995498000
- tz.transition 2033, 10, :o1, 2014246800
- tz.transition 2034, 3, :o2, 2026947600
- tz.transition 2034, 10, :o1, 2045696400
- tz.transition 2035, 3, :o2, 2058397200
- tz.transition 2035, 10, :o1, 2077146000
- tz.transition 2036, 3, :o2, 2090451600
- tz.transition 2036, 10, :o1, 2108595600
- tz.transition 2037, 3, :o2, 2121901200
- tz.transition 2037, 10, :o1, 2140045200
- tz.transition 2038, 3, :o2, 59172253, 24
- tz.transition 2038, 10, :o1, 59177461, 24
- tz.transition 2039, 3, :o2, 59180989, 24
- tz.transition 2039, 10, :o1, 59186197, 24
- tz.transition 2040, 3, :o2, 59189725, 24
- tz.transition 2040, 10, :o1, 59194933, 24
- tz.transition 2041, 3, :o2, 59198629, 24
- tz.transition 2041, 10, :o1, 59203669, 24
- tz.transition 2042, 3, :o2, 59207365, 24
- tz.transition 2042, 10, :o1, 59212405, 24
- tz.transition 2043, 3, :o2, 59216101, 24
- tz.transition 2043, 10, :o1, 59221141, 24
- tz.transition 2044, 3, :o2, 59224837, 24
- tz.transition 2044, 10, :o1, 59230045, 24
- tz.transition 2045, 3, :o2, 59233573, 24
- tz.transition 2045, 10, :o1, 59238781, 24
- tz.transition 2046, 3, :o2, 59242309, 24
- tz.transition 2046, 10, :o1, 59247517, 24
- tz.transition 2047, 3, :o2, 59251213, 24
- tz.transition 2047, 10, :o1, 59256253, 24
- tz.transition 2048, 3, :o2, 59259949, 24
- tz.transition 2048, 10, :o1, 59264989, 24
- tz.transition 2049, 3, :o2, 59268685, 24
- tz.transition 2049, 10, :o1, 59273893, 24
- tz.transition 2050, 3, :o2, 59277421, 24
- tz.transition 2050, 10, :o1, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Bratislava.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Bratislava.rb
deleted file mode 100644
index 7a731a0b6a..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Bratislava.rb
+++ /dev/null
@@ -1,13 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Bratislava
- include TimezoneDefinition
-
- linked_timezone 'Europe/Bratislava', 'Europe/Prague'
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Brussels.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Brussels.rb
deleted file mode 100644
index 6b0a242944..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Brussels.rb
+++ /dev/null
@@ -1,232 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Brussels
- include TimezoneDefinition
-
- timezone 'Europe/Brussels' do |tz|
- tz.offset :o0, 1050, 0, :LMT
- tz.offset :o1, 1050, 0, :BMT
- tz.offset :o2, 0, 0, :WET
- tz.offset :o3, 3600, 0, :CET
- tz.offset :o4, 3600, 3600, :CEST
- tz.offset :o5, 0, 3600, :WEST
-
- tz.transition 1879, 12, :o1, 1386844121, 576
- tz.transition 1892, 5, :o2, 1389438713, 576
- tz.transition 1914, 11, :o3, 4840889, 2
- tz.transition 1916, 4, :o4, 58103627, 24
- tz.transition 1916, 9, :o3, 58107299, 24
- tz.transition 1917, 4, :o4, 58112029, 24
- tz.transition 1917, 9, :o3, 58115725, 24
- tz.transition 1918, 4, :o4, 58120765, 24
- tz.transition 1918, 9, :o3, 58124461, 24
- tz.transition 1918, 11, :o2, 58125815, 24
- tz.transition 1919, 3, :o5, 58128467, 24
- tz.transition 1919, 10, :o2, 58133675, 24
- tz.transition 1920, 2, :o5, 58136867, 24
- tz.transition 1920, 10, :o2, 58142915, 24
- tz.transition 1921, 3, :o5, 58146323, 24
- tz.transition 1921, 10, :o2, 58151723, 24
- tz.transition 1922, 3, :o5, 58155347, 24
- tz.transition 1922, 10, :o2, 58160051, 24
- tz.transition 1923, 4, :o5, 58164755, 24
- tz.transition 1923, 10, :o2, 58168787, 24
- tz.transition 1924, 3, :o5, 58172987, 24
- tz.transition 1924, 10, :o2, 58177523, 24
- tz.transition 1925, 4, :o5, 58181891, 24
- tz.transition 1925, 10, :o2, 58186259, 24
- tz.transition 1926, 4, :o5, 58190963, 24
- tz.transition 1926, 10, :o2, 58194995, 24
- tz.transition 1927, 4, :o5, 58199531, 24
- tz.transition 1927, 10, :o2, 58203731, 24
- tz.transition 1928, 4, :o5, 58208435, 24
- tz.transition 1928, 10, :o2, 29106319, 12
- tz.transition 1929, 4, :o5, 29108671, 12
- tz.transition 1929, 10, :o2, 29110687, 12
- tz.transition 1930, 4, :o5, 29112955, 12
- tz.transition 1930, 10, :o2, 29115055, 12
- tz.transition 1931, 4, :o5, 29117407, 12
- tz.transition 1931, 10, :o2, 29119423, 12
- tz.transition 1932, 4, :o5, 29121607, 12
- tz.transition 1932, 10, :o2, 29123791, 12
- tz.transition 1933, 3, :o5, 29125891, 12
- tz.transition 1933, 10, :o2, 29128243, 12
- tz.transition 1934, 4, :o5, 29130427, 12
- tz.transition 1934, 10, :o2, 29132611, 12
- tz.transition 1935, 3, :o5, 29134711, 12
- tz.transition 1935, 10, :o2, 29136979, 12
- tz.transition 1936, 4, :o5, 29139331, 12
- tz.transition 1936, 10, :o2, 29141347, 12
- tz.transition 1937, 4, :o5, 29143531, 12
- tz.transition 1937, 10, :o2, 29145715, 12
- tz.transition 1938, 3, :o5, 29147815, 12
- tz.transition 1938, 10, :o2, 29150083, 12
- tz.transition 1939, 4, :o5, 29152435, 12
- tz.transition 1939, 11, :o2, 29155039, 12
- tz.transition 1940, 2, :o5, 29156215, 12
- tz.transition 1940, 5, :o4, 29157235, 12
- tz.transition 1942, 11, :o3, 58335973, 24
- tz.transition 1943, 3, :o4, 58339501, 24
- tz.transition 1943, 10, :o3, 58344037, 24
- tz.transition 1944, 4, :o4, 58348405, 24
- tz.transition 1944, 9, :o3, 58352413, 24
- tz.transition 1945, 4, :o4, 58357141, 24
- tz.transition 1945, 9, :o3, 58361149, 24
- tz.transition 1946, 5, :o4, 58367029, 24
- tz.transition 1946, 10, :o3, 58370413, 24
- tz.transition 1977, 4, :o4, 228877200
- tz.transition 1977, 9, :o3, 243997200
- tz.transition 1978, 4, :o4, 260326800
- tz.transition 1978, 10, :o3, 276051600
- tz.transition 1979, 4, :o4, 291776400
- tz.transition 1979, 9, :o3, 307501200
- tz.transition 1980, 4, :o4, 323830800
- tz.transition 1980, 9, :o3, 338950800
- tz.transition 1981, 3, :o4, 354675600
- tz.transition 1981, 9, :o3, 370400400
- tz.transition 1982, 3, :o4, 386125200
- tz.transition 1982, 9, :o3, 401850000
- tz.transition 1983, 3, :o4, 417574800
- tz.transition 1983, 9, :o3, 433299600
- tz.transition 1984, 3, :o4, 449024400
- tz.transition 1984, 9, :o3, 465354000
- tz.transition 1985, 3, :o4, 481078800
- tz.transition 1985, 9, :o3, 496803600
- tz.transition 1986, 3, :o4, 512528400
- tz.transition 1986, 9, :o3, 528253200
- tz.transition 1987, 3, :o4, 543978000
- tz.transition 1987, 9, :o3, 559702800
- tz.transition 1988, 3, :o4, 575427600
- tz.transition 1988, 9, :o3, 591152400
- tz.transition 1989, 3, :o4, 606877200
- tz.transition 1989, 9, :o3, 622602000
- tz.transition 1990, 3, :o4, 638326800
- tz.transition 1990, 9, :o3, 654656400
- tz.transition 1991, 3, :o4, 670381200
- tz.transition 1991, 9, :o3, 686106000
- tz.transition 1992, 3, :o4, 701830800
- tz.transition 1992, 9, :o3, 717555600
- tz.transition 1993, 3, :o4, 733280400
- tz.transition 1993, 9, :o3, 749005200
- tz.transition 1994, 3, :o4, 764730000
- tz.transition 1994, 9, :o3, 780454800
- tz.transition 1995, 3, :o4, 796179600
- tz.transition 1995, 9, :o3, 811904400
- tz.transition 1996, 3, :o4, 828234000
- tz.transition 1996, 10, :o3, 846378000
- tz.transition 1997, 3, :o4, 859683600
- tz.transition 1997, 10, :o3, 877827600
- tz.transition 1998, 3, :o4, 891133200
- tz.transition 1998, 10, :o3, 909277200
- tz.transition 1999, 3, :o4, 922582800
- tz.transition 1999, 10, :o3, 941331600
- tz.transition 2000, 3, :o4, 954032400
- tz.transition 2000, 10, :o3, 972781200
- tz.transition 2001, 3, :o4, 985482000
- tz.transition 2001, 10, :o3, 1004230800
- tz.transition 2002, 3, :o4, 1017536400
- tz.transition 2002, 10, :o3, 1035680400
- tz.transition 2003, 3, :o4, 1048986000
- tz.transition 2003, 10, :o3, 1067130000
- tz.transition 2004, 3, :o4, 1080435600
- tz.transition 2004, 10, :o3, 1099184400
- tz.transition 2005, 3, :o4, 1111885200
- tz.transition 2005, 10, :o3, 1130634000
- tz.transition 2006, 3, :o4, 1143334800
- tz.transition 2006, 10, :o3, 1162083600
- tz.transition 2007, 3, :o4, 1174784400
- tz.transition 2007, 10, :o3, 1193533200
- tz.transition 2008, 3, :o4, 1206838800
- tz.transition 2008, 10, :o3, 1224982800
- tz.transition 2009, 3, :o4, 1238288400
- tz.transition 2009, 10, :o3, 1256432400
- tz.transition 2010, 3, :o4, 1269738000
- tz.transition 2010, 10, :o3, 1288486800
- tz.transition 2011, 3, :o4, 1301187600
- tz.transition 2011, 10, :o3, 1319936400
- tz.transition 2012, 3, :o4, 1332637200
- tz.transition 2012, 10, :o3, 1351386000
- tz.transition 2013, 3, :o4, 1364691600
- tz.transition 2013, 10, :o3, 1382835600
- tz.transition 2014, 3, :o4, 1396141200
- tz.transition 2014, 10, :o3, 1414285200
- tz.transition 2015, 3, :o4, 1427590800
- tz.transition 2015, 10, :o3, 1445734800
- tz.transition 2016, 3, :o4, 1459040400
- tz.transition 2016, 10, :o3, 1477789200
- tz.transition 2017, 3, :o4, 1490490000
- tz.transition 2017, 10, :o3, 1509238800
- tz.transition 2018, 3, :o4, 1521939600
- tz.transition 2018, 10, :o3, 1540688400
- tz.transition 2019, 3, :o4, 1553994000
- tz.transition 2019, 10, :o3, 1572138000
- tz.transition 2020, 3, :o4, 1585443600
- tz.transition 2020, 10, :o3, 1603587600
- tz.transition 2021, 3, :o4, 1616893200
- tz.transition 2021, 10, :o3, 1635642000
- tz.transition 2022, 3, :o4, 1648342800
- tz.transition 2022, 10, :o3, 1667091600
- tz.transition 2023, 3, :o4, 1679792400
- tz.transition 2023, 10, :o3, 1698541200
- tz.transition 2024, 3, :o4, 1711846800
- tz.transition 2024, 10, :o3, 1729990800
- tz.transition 2025, 3, :o4, 1743296400
- tz.transition 2025, 10, :o3, 1761440400
- tz.transition 2026, 3, :o4, 1774746000
- tz.transition 2026, 10, :o3, 1792890000
- tz.transition 2027, 3, :o4, 1806195600
- tz.transition 2027, 10, :o3, 1824944400
- tz.transition 2028, 3, :o4, 1837645200
- tz.transition 2028, 10, :o3, 1856394000
- tz.transition 2029, 3, :o4, 1869094800
- tz.transition 2029, 10, :o3, 1887843600
- tz.transition 2030, 3, :o4, 1901149200
- tz.transition 2030, 10, :o3, 1919293200
- tz.transition 2031, 3, :o4, 1932598800
- tz.transition 2031, 10, :o3, 1950742800
- tz.transition 2032, 3, :o4, 1964048400
- tz.transition 2032, 10, :o3, 1982797200
- tz.transition 2033, 3, :o4, 1995498000
- tz.transition 2033, 10, :o3, 2014246800
- tz.transition 2034, 3, :o4, 2026947600
- tz.transition 2034, 10, :o3, 2045696400
- tz.transition 2035, 3, :o4, 2058397200
- tz.transition 2035, 10, :o3, 2077146000
- tz.transition 2036, 3, :o4, 2090451600
- tz.transition 2036, 10, :o3, 2108595600
- tz.transition 2037, 3, :o4, 2121901200
- tz.transition 2037, 10, :o3, 2140045200
- tz.transition 2038, 3, :o4, 59172253, 24
- tz.transition 2038, 10, :o3, 59177461, 24
- tz.transition 2039, 3, :o4, 59180989, 24
- tz.transition 2039, 10, :o3, 59186197, 24
- tz.transition 2040, 3, :o4, 59189725, 24
- tz.transition 2040, 10, :o3, 59194933, 24
- tz.transition 2041, 3, :o4, 59198629, 24
- tz.transition 2041, 10, :o3, 59203669, 24
- tz.transition 2042, 3, :o4, 59207365, 24
- tz.transition 2042, 10, :o3, 59212405, 24
- tz.transition 2043, 3, :o4, 59216101, 24
- tz.transition 2043, 10, :o3, 59221141, 24
- tz.transition 2044, 3, :o4, 59224837, 24
- tz.transition 2044, 10, :o3, 59230045, 24
- tz.transition 2045, 3, :o4, 59233573, 24
- tz.transition 2045, 10, :o3, 59238781, 24
- tz.transition 2046, 3, :o4, 59242309, 24
- tz.transition 2046, 10, :o3, 59247517, 24
- tz.transition 2047, 3, :o4, 59251213, 24
- tz.transition 2047, 10, :o3, 59256253, 24
- tz.transition 2048, 3, :o4, 59259949, 24
- tz.transition 2048, 10, :o3, 59264989, 24
- tz.transition 2049, 3, :o4, 59268685, 24
- tz.transition 2049, 10, :o3, 59273893, 24
- tz.transition 2050, 3, :o4, 59277421, 24
- tz.transition 2050, 10, :o3, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Bucharest.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Bucharest.rb
deleted file mode 100644
index 521c3c932e..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Bucharest.rb
+++ /dev/null
@@ -1,181 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Bucharest
- include TimezoneDefinition
-
- timezone 'Europe/Bucharest' do |tz|
- tz.offset :o0, 6264, 0, :LMT
- tz.offset :o1, 6264, 0, :BMT
- tz.offset :o2, 7200, 0, :EET
- tz.offset :o3, 7200, 3600, :EEST
-
- tz.transition 1891, 9, :o1, 964802571, 400
- tz.transition 1931, 7, :o2, 970618571, 400
- tz.transition 1932, 5, :o3, 29122181, 12
- tz.transition 1932, 10, :o2, 29123789, 12
- tz.transition 1933, 4, :o3, 29125973, 12
- tz.transition 1933, 9, :o2, 29128157, 12
- tz.transition 1934, 4, :o3, 29130425, 12
- tz.transition 1934, 10, :o2, 29132609, 12
- tz.transition 1935, 4, :o3, 29134793, 12
- tz.transition 1935, 10, :o2, 29136977, 12
- tz.transition 1936, 4, :o3, 29139161, 12
- tz.transition 1936, 10, :o2, 29141345, 12
- tz.transition 1937, 4, :o3, 29143529, 12
- tz.transition 1937, 10, :o2, 29145713, 12
- tz.transition 1938, 4, :o3, 29147897, 12
- tz.transition 1938, 10, :o2, 29150081, 12
- tz.transition 1939, 4, :o3, 29152265, 12
- tz.transition 1939, 9, :o2, 29154449, 12
- tz.transition 1979, 5, :o3, 296604000
- tz.transition 1979, 9, :o2, 307486800
- tz.transition 1980, 4, :o3, 323816400
- tz.transition 1980, 9, :o2, 338940000
- tz.transition 1981, 3, :o3, 354672000
- tz.transition 1981, 9, :o2, 370396800
- tz.transition 1982, 3, :o3, 386121600
- tz.transition 1982, 9, :o2, 401846400
- tz.transition 1983, 3, :o3, 417571200
- tz.transition 1983, 9, :o2, 433296000
- tz.transition 1984, 3, :o3, 449020800
- tz.transition 1984, 9, :o2, 465350400
- tz.transition 1985, 3, :o3, 481075200
- tz.transition 1985, 9, :o2, 496800000
- tz.transition 1986, 3, :o3, 512524800
- tz.transition 1986, 9, :o2, 528249600
- tz.transition 1987, 3, :o3, 543974400
- tz.transition 1987, 9, :o2, 559699200
- tz.transition 1988, 3, :o3, 575424000
- tz.transition 1988, 9, :o2, 591148800
- tz.transition 1989, 3, :o3, 606873600
- tz.transition 1989, 9, :o2, 622598400
- tz.transition 1990, 3, :o3, 638323200
- tz.transition 1990, 9, :o2, 654652800
- tz.transition 1991, 3, :o3, 670370400
- tz.transition 1991, 9, :o2, 686095200
- tz.transition 1992, 3, :o3, 701820000
- tz.transition 1992, 9, :o2, 717544800
- tz.transition 1993, 3, :o3, 733269600
- tz.transition 1993, 9, :o2, 748994400
- tz.transition 1994, 3, :o3, 764719200
- tz.transition 1994, 9, :o2, 780440400
- tz.transition 1995, 3, :o3, 796168800
- tz.transition 1995, 9, :o2, 811890000
- tz.transition 1996, 3, :o3, 828223200
- tz.transition 1996, 10, :o2, 846363600
- tz.transition 1997, 3, :o3, 859683600
- tz.transition 1997, 10, :o2, 877827600
- tz.transition 1998, 3, :o3, 891133200
- tz.transition 1998, 10, :o2, 909277200
- tz.transition 1999, 3, :o3, 922582800
- tz.transition 1999, 10, :o2, 941331600
- tz.transition 2000, 3, :o3, 954032400
- tz.transition 2000, 10, :o2, 972781200
- tz.transition 2001, 3, :o3, 985482000
- tz.transition 2001, 10, :o2, 1004230800
- tz.transition 2002, 3, :o3, 1017536400
- tz.transition 2002, 10, :o2, 1035680400
- tz.transition 2003, 3, :o3, 1048986000
- tz.transition 2003, 10, :o2, 1067130000
- tz.transition 2004, 3, :o3, 1080435600
- tz.transition 2004, 10, :o2, 1099184400
- tz.transition 2005, 3, :o3, 1111885200
- tz.transition 2005, 10, :o2, 1130634000
- tz.transition 2006, 3, :o3, 1143334800
- tz.transition 2006, 10, :o2, 1162083600
- tz.transition 2007, 3, :o3, 1174784400
- tz.transition 2007, 10, :o2, 1193533200
- tz.transition 2008, 3, :o3, 1206838800
- tz.transition 2008, 10, :o2, 1224982800
- tz.transition 2009, 3, :o3, 1238288400
- tz.transition 2009, 10, :o2, 1256432400
- tz.transition 2010, 3, :o3, 1269738000
- tz.transition 2010, 10, :o2, 1288486800
- tz.transition 2011, 3, :o3, 1301187600
- tz.transition 2011, 10, :o2, 1319936400
- tz.transition 2012, 3, :o3, 1332637200
- tz.transition 2012, 10, :o2, 1351386000
- tz.transition 2013, 3, :o3, 1364691600
- tz.transition 2013, 10, :o2, 1382835600
- tz.transition 2014, 3, :o3, 1396141200
- tz.transition 2014, 10, :o2, 1414285200
- tz.transition 2015, 3, :o3, 1427590800
- tz.transition 2015, 10, :o2, 1445734800
- tz.transition 2016, 3, :o3, 1459040400
- tz.transition 2016, 10, :o2, 1477789200
- tz.transition 2017, 3, :o3, 1490490000
- tz.transition 2017, 10, :o2, 1509238800
- tz.transition 2018, 3, :o3, 1521939600
- tz.transition 2018, 10, :o2, 1540688400
- tz.transition 2019, 3, :o3, 1553994000
- tz.transition 2019, 10, :o2, 1572138000
- tz.transition 2020, 3, :o3, 1585443600
- tz.transition 2020, 10, :o2, 1603587600
- tz.transition 2021, 3, :o3, 1616893200
- tz.transition 2021, 10, :o2, 1635642000
- tz.transition 2022, 3, :o3, 1648342800
- tz.transition 2022, 10, :o2, 1667091600
- tz.transition 2023, 3, :o3, 1679792400
- tz.transition 2023, 10, :o2, 1698541200
- tz.transition 2024, 3, :o3, 1711846800
- tz.transition 2024, 10, :o2, 1729990800
- tz.transition 2025, 3, :o3, 1743296400
- tz.transition 2025, 10, :o2, 1761440400
- tz.transition 2026, 3, :o3, 1774746000
- tz.transition 2026, 10, :o2, 1792890000
- tz.transition 2027, 3, :o3, 1806195600
- tz.transition 2027, 10, :o2, 1824944400
- tz.transition 2028, 3, :o3, 1837645200
- tz.transition 2028, 10, :o2, 1856394000
- tz.transition 2029, 3, :o3, 1869094800
- tz.transition 2029, 10, :o2, 1887843600
- tz.transition 2030, 3, :o3, 1901149200
- tz.transition 2030, 10, :o2, 1919293200
- tz.transition 2031, 3, :o3, 1932598800
- tz.transition 2031, 10, :o2, 1950742800
- tz.transition 2032, 3, :o3, 1964048400
- tz.transition 2032, 10, :o2, 1982797200
- tz.transition 2033, 3, :o3, 1995498000
- tz.transition 2033, 10, :o2, 2014246800
- tz.transition 2034, 3, :o3, 2026947600
- tz.transition 2034, 10, :o2, 2045696400
- tz.transition 2035, 3, :o3, 2058397200
- tz.transition 2035, 10, :o2, 2077146000
- tz.transition 2036, 3, :o3, 2090451600
- tz.transition 2036, 10, :o2, 2108595600
- tz.transition 2037, 3, :o3, 2121901200
- tz.transition 2037, 10, :o2, 2140045200
- tz.transition 2038, 3, :o3, 59172253, 24
- tz.transition 2038, 10, :o2, 59177461, 24
- tz.transition 2039, 3, :o3, 59180989, 24
- tz.transition 2039, 10, :o2, 59186197, 24
- tz.transition 2040, 3, :o3, 59189725, 24
- tz.transition 2040, 10, :o2, 59194933, 24
- tz.transition 2041, 3, :o3, 59198629, 24
- tz.transition 2041, 10, :o2, 59203669, 24
- tz.transition 2042, 3, :o3, 59207365, 24
- tz.transition 2042, 10, :o2, 59212405, 24
- tz.transition 2043, 3, :o3, 59216101, 24
- tz.transition 2043, 10, :o2, 59221141, 24
- tz.transition 2044, 3, :o3, 59224837, 24
- tz.transition 2044, 10, :o2, 59230045, 24
- tz.transition 2045, 3, :o3, 59233573, 24
- tz.transition 2045, 10, :o2, 59238781, 24
- tz.transition 2046, 3, :o3, 59242309, 24
- tz.transition 2046, 10, :o2, 59247517, 24
- tz.transition 2047, 3, :o3, 59251213, 24
- tz.transition 2047, 10, :o2, 59256253, 24
- tz.transition 2048, 3, :o3, 59259949, 24
- tz.transition 2048, 10, :o2, 59264989, 24
- tz.transition 2049, 3, :o3, 59268685, 24
- tz.transition 2049, 10, :o2, 59273893, 24
- tz.transition 2050, 3, :o3, 59277421, 24
- tz.transition 2050, 10, :o2, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Budapest.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Budapest.rb
deleted file mode 100644
index 1f3a9738b7..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Budapest.rb
+++ /dev/null
@@ -1,197 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Budapest
- include TimezoneDefinition
-
- timezone 'Europe/Budapest' do |tz|
- tz.offset :o0, 4580, 0, :LMT
- tz.offset :o1, 3600, 0, :CET
- tz.offset :o2, 3600, 3600, :CEST
-
- tz.transition 1890, 9, :o1, 10418291051, 4320
- tz.transition 1916, 4, :o2, 29051813, 12
- tz.transition 1916, 9, :o1, 58107299, 24
- tz.transition 1917, 4, :o2, 58112029, 24
- tz.transition 1917, 9, :o1, 58115725, 24
- tz.transition 1918, 4, :o2, 29060215, 12
- tz.transition 1918, 9, :o1, 58124773, 24
- tz.transition 1919, 4, :o2, 29064763, 12
- tz.transition 1919, 9, :o1, 58133197, 24
- tz.transition 1920, 4, :o2, 29069035, 12
- tz.transition 1920, 9, :o1, 58142341, 24
- tz.transition 1941, 4, :o2, 58322173, 24
- tz.transition 1942, 11, :o1, 58335973, 24
- tz.transition 1943, 3, :o2, 58339501, 24
- tz.transition 1943, 10, :o1, 58344037, 24
- tz.transition 1944, 4, :o2, 58348405, 24
- tz.transition 1944, 10, :o1, 58352773, 24
- tz.transition 1945, 5, :o2, 29178929, 12
- tz.transition 1945, 11, :o1, 29181149, 12
- tz.transition 1946, 3, :o2, 58365853, 24
- tz.transition 1946, 10, :o1, 58370389, 24
- tz.transition 1947, 4, :o2, 58374757, 24
- tz.transition 1947, 10, :o1, 58379125, 24
- tz.transition 1948, 4, :o2, 58383493, 24
- tz.transition 1948, 10, :o1, 58387861, 24
- tz.transition 1949, 4, :o2, 58392397, 24
- tz.transition 1949, 10, :o1, 58396597, 24
- tz.transition 1950, 4, :o2, 58401325, 24
- tz.transition 1950, 10, :o1, 58405861, 24
- tz.transition 1954, 5, :o2, 58437251, 24
- tz.transition 1954, 10, :o1, 29220221, 12
- tz.transition 1955, 5, :o2, 58446011, 24
- tz.transition 1955, 10, :o1, 29224601, 12
- tz.transition 1956, 6, :o2, 58455059, 24
- tz.transition 1956, 9, :o1, 29228957, 12
- tz.transition 1957, 6, :o2, 4871983, 2
- tz.transition 1957, 9, :o1, 58466653, 24
- tz.transition 1980, 4, :o2, 323827200
- tz.transition 1980, 9, :o1, 338950800
- tz.transition 1981, 3, :o2, 354675600
- tz.transition 1981, 9, :o1, 370400400
- tz.transition 1982, 3, :o2, 386125200
- tz.transition 1982, 9, :o1, 401850000
- tz.transition 1983, 3, :o2, 417574800
- tz.transition 1983, 9, :o1, 433299600
- tz.transition 1984, 3, :o2, 449024400
- tz.transition 1984, 9, :o1, 465354000
- tz.transition 1985, 3, :o2, 481078800
- tz.transition 1985, 9, :o1, 496803600
- tz.transition 1986, 3, :o2, 512528400
- tz.transition 1986, 9, :o1, 528253200
- tz.transition 1987, 3, :o2, 543978000
- tz.transition 1987, 9, :o1, 559702800
- tz.transition 1988, 3, :o2, 575427600
- tz.transition 1988, 9, :o1, 591152400
- tz.transition 1989, 3, :o2, 606877200
- tz.transition 1989, 9, :o1, 622602000
- tz.transition 1990, 3, :o2, 638326800
- tz.transition 1990, 9, :o1, 654656400
- tz.transition 1991, 3, :o2, 670381200
- tz.transition 1991, 9, :o1, 686106000
- tz.transition 1992, 3, :o2, 701830800
- tz.transition 1992, 9, :o1, 717555600
- tz.transition 1993, 3, :o2, 733280400
- tz.transition 1993, 9, :o1, 749005200
- tz.transition 1994, 3, :o2, 764730000
- tz.transition 1994, 9, :o1, 780454800
- tz.transition 1995, 3, :o2, 796179600
- tz.transition 1995, 9, :o1, 811904400
- tz.transition 1996, 3, :o2, 828234000
- tz.transition 1996, 10, :o1, 846378000
- tz.transition 1997, 3, :o2, 859683600
- tz.transition 1997, 10, :o1, 877827600
- tz.transition 1998, 3, :o2, 891133200
- tz.transition 1998, 10, :o1, 909277200
- tz.transition 1999, 3, :o2, 922582800
- tz.transition 1999, 10, :o1, 941331600
- tz.transition 2000, 3, :o2, 954032400
- tz.transition 2000, 10, :o1, 972781200
- tz.transition 2001, 3, :o2, 985482000
- tz.transition 2001, 10, :o1, 1004230800
- tz.transition 2002, 3, :o2, 1017536400
- tz.transition 2002, 10, :o1, 1035680400
- tz.transition 2003, 3, :o2, 1048986000
- tz.transition 2003, 10, :o1, 1067130000
- tz.transition 2004, 3, :o2, 1080435600
- tz.transition 2004, 10, :o1, 1099184400
- tz.transition 2005, 3, :o2, 1111885200
- tz.transition 2005, 10, :o1, 1130634000
- tz.transition 2006, 3, :o2, 1143334800
- tz.transition 2006, 10, :o1, 1162083600
- tz.transition 2007, 3, :o2, 1174784400
- tz.transition 2007, 10, :o1, 1193533200
- tz.transition 2008, 3, :o2, 1206838800
- tz.transition 2008, 10, :o1, 1224982800
- tz.transition 2009, 3, :o2, 1238288400
- tz.transition 2009, 10, :o1, 1256432400
- tz.transition 2010, 3, :o2, 1269738000
- tz.transition 2010, 10, :o1, 1288486800
- tz.transition 2011, 3, :o2, 1301187600
- tz.transition 2011, 10, :o1, 1319936400
- tz.transition 2012, 3, :o2, 1332637200
- tz.transition 2012, 10, :o1, 1351386000
- tz.transition 2013, 3, :o2, 1364691600
- tz.transition 2013, 10, :o1, 1382835600
- tz.transition 2014, 3, :o2, 1396141200
- tz.transition 2014, 10, :o1, 1414285200
- tz.transition 2015, 3, :o2, 1427590800
- tz.transition 2015, 10, :o1, 1445734800
- tz.transition 2016, 3, :o2, 1459040400
- tz.transition 2016, 10, :o1, 1477789200
- tz.transition 2017, 3, :o2, 1490490000
- tz.transition 2017, 10, :o1, 1509238800
- tz.transition 2018, 3, :o2, 1521939600
- tz.transition 2018, 10, :o1, 1540688400
- tz.transition 2019, 3, :o2, 1553994000
- tz.transition 2019, 10, :o1, 1572138000
- tz.transition 2020, 3, :o2, 1585443600
- tz.transition 2020, 10, :o1, 1603587600
- tz.transition 2021, 3, :o2, 1616893200
- tz.transition 2021, 10, :o1, 1635642000
- tz.transition 2022, 3, :o2, 1648342800
- tz.transition 2022, 10, :o1, 1667091600
- tz.transition 2023, 3, :o2, 1679792400
- tz.transition 2023, 10, :o1, 1698541200
- tz.transition 2024, 3, :o2, 1711846800
- tz.transition 2024, 10, :o1, 1729990800
- tz.transition 2025, 3, :o2, 1743296400
- tz.transition 2025, 10, :o1, 1761440400
- tz.transition 2026, 3, :o2, 1774746000
- tz.transition 2026, 10, :o1, 1792890000
- tz.transition 2027, 3, :o2, 1806195600
- tz.transition 2027, 10, :o1, 1824944400
- tz.transition 2028, 3, :o2, 1837645200
- tz.transition 2028, 10, :o1, 1856394000
- tz.transition 2029, 3, :o2, 1869094800
- tz.transition 2029, 10, :o1, 1887843600
- tz.transition 2030, 3, :o2, 1901149200
- tz.transition 2030, 10, :o1, 1919293200
- tz.transition 2031, 3, :o2, 1932598800
- tz.transition 2031, 10, :o1, 1950742800
- tz.transition 2032, 3, :o2, 1964048400
- tz.transition 2032, 10, :o1, 1982797200
- tz.transition 2033, 3, :o2, 1995498000
- tz.transition 2033, 10, :o1, 2014246800
- tz.transition 2034, 3, :o2, 2026947600
- tz.transition 2034, 10, :o1, 2045696400
- tz.transition 2035, 3, :o2, 2058397200
- tz.transition 2035, 10, :o1, 2077146000
- tz.transition 2036, 3, :o2, 2090451600
- tz.transition 2036, 10, :o1, 2108595600
- tz.transition 2037, 3, :o2, 2121901200
- tz.transition 2037, 10, :o1, 2140045200
- tz.transition 2038, 3, :o2, 59172253, 24
- tz.transition 2038, 10, :o1, 59177461, 24
- tz.transition 2039, 3, :o2, 59180989, 24
- tz.transition 2039, 10, :o1, 59186197, 24
- tz.transition 2040, 3, :o2, 59189725, 24
- tz.transition 2040, 10, :o1, 59194933, 24
- tz.transition 2041, 3, :o2, 59198629, 24
- tz.transition 2041, 10, :o1, 59203669, 24
- tz.transition 2042, 3, :o2, 59207365, 24
- tz.transition 2042, 10, :o1, 59212405, 24
- tz.transition 2043, 3, :o2, 59216101, 24
- tz.transition 2043, 10, :o1, 59221141, 24
- tz.transition 2044, 3, :o2, 59224837, 24
- tz.transition 2044, 10, :o1, 59230045, 24
- tz.transition 2045, 3, :o2, 59233573, 24
- tz.transition 2045, 10, :o1, 59238781, 24
- tz.transition 2046, 3, :o2, 59242309, 24
- tz.transition 2046, 10, :o1, 59247517, 24
- tz.transition 2047, 3, :o2, 59251213, 24
- tz.transition 2047, 10, :o1, 59256253, 24
- tz.transition 2048, 3, :o2, 59259949, 24
- tz.transition 2048, 10, :o1, 59264989, 24
- tz.transition 2049, 3, :o2, 59268685, 24
- tz.transition 2049, 10, :o1, 59273893, 24
- tz.transition 2050, 3, :o2, 59277421, 24
- tz.transition 2050, 10, :o1, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Copenhagen.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Copenhagen.rb
deleted file mode 100644
index 47cbaf14a7..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Copenhagen.rb
+++ /dev/null
@@ -1,179 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Copenhagen
- include TimezoneDefinition
-
- timezone 'Europe/Copenhagen' do |tz|
- tz.offset :o0, 3020, 0, :LMT
- tz.offset :o1, 3020, 0, :CMT
- tz.offset :o2, 3600, 0, :CET
- tz.offset :o3, 3600, 3600, :CEST
-
- tz.transition 1889, 12, :o1, 10417111769, 4320
- tz.transition 1893, 12, :o2, 10423423289, 4320
- tz.transition 1916, 5, :o3, 29051981, 12
- tz.transition 1916, 9, :o2, 19369099, 8
- tz.transition 1940, 5, :o3, 58314347, 24
- tz.transition 1942, 11, :o2, 58335973, 24
- tz.transition 1943, 3, :o3, 58339501, 24
- tz.transition 1943, 10, :o2, 58344037, 24
- tz.transition 1944, 4, :o3, 58348405, 24
- tz.transition 1944, 10, :o2, 58352773, 24
- tz.transition 1945, 4, :o3, 58357141, 24
- tz.transition 1945, 8, :o2, 58360381, 24
- tz.transition 1946, 5, :o3, 58366597, 24
- tz.transition 1946, 9, :o2, 58369549, 24
- tz.transition 1947, 5, :o3, 58375429, 24
- tz.transition 1947, 8, :o2, 58377781, 24
- tz.transition 1948, 5, :o3, 58384333, 24
- tz.transition 1948, 8, :o2, 58386517, 24
- tz.transition 1980, 4, :o3, 323830800
- tz.transition 1980, 9, :o2, 338950800
- tz.transition 1981, 3, :o3, 354675600
- tz.transition 1981, 9, :o2, 370400400
- tz.transition 1982, 3, :o3, 386125200
- tz.transition 1982, 9, :o2, 401850000
- tz.transition 1983, 3, :o3, 417574800
- tz.transition 1983, 9, :o2, 433299600
- tz.transition 1984, 3, :o3, 449024400
- tz.transition 1984, 9, :o2, 465354000
- tz.transition 1985, 3, :o3, 481078800
- tz.transition 1985, 9, :o2, 496803600
- tz.transition 1986, 3, :o3, 512528400
- tz.transition 1986, 9, :o2, 528253200
- tz.transition 1987, 3, :o3, 543978000
- tz.transition 1987, 9, :o2, 559702800
- tz.transition 1988, 3, :o3, 575427600
- tz.transition 1988, 9, :o2, 591152400
- tz.transition 1989, 3, :o3, 606877200
- tz.transition 1989, 9, :o2, 622602000
- tz.transition 1990, 3, :o3, 638326800
- tz.transition 1990, 9, :o2, 654656400
- tz.transition 1991, 3, :o3, 670381200
- tz.transition 1991, 9, :o2, 686106000
- tz.transition 1992, 3, :o3, 701830800
- tz.transition 1992, 9, :o2, 717555600
- tz.transition 1993, 3, :o3, 733280400
- tz.transition 1993, 9, :o2, 749005200
- tz.transition 1994, 3, :o3, 764730000
- tz.transition 1994, 9, :o2, 780454800
- tz.transition 1995, 3, :o3, 796179600
- tz.transition 1995, 9, :o2, 811904400
- tz.transition 1996, 3, :o3, 828234000
- tz.transition 1996, 10, :o2, 846378000
- tz.transition 1997, 3, :o3, 859683600
- tz.transition 1997, 10, :o2, 877827600
- tz.transition 1998, 3, :o3, 891133200
- tz.transition 1998, 10, :o2, 909277200
- tz.transition 1999, 3, :o3, 922582800
- tz.transition 1999, 10, :o2, 941331600
- tz.transition 2000, 3, :o3, 954032400
- tz.transition 2000, 10, :o2, 972781200
- tz.transition 2001, 3, :o3, 985482000
- tz.transition 2001, 10, :o2, 1004230800
- tz.transition 2002, 3, :o3, 1017536400
- tz.transition 2002, 10, :o2, 1035680400
- tz.transition 2003, 3, :o3, 1048986000
- tz.transition 2003, 10, :o2, 1067130000
- tz.transition 2004, 3, :o3, 1080435600
- tz.transition 2004, 10, :o2, 1099184400
- tz.transition 2005, 3, :o3, 1111885200
- tz.transition 2005, 10, :o2, 1130634000
- tz.transition 2006, 3, :o3, 1143334800
- tz.transition 2006, 10, :o2, 1162083600
- tz.transition 2007, 3, :o3, 1174784400
- tz.transition 2007, 10, :o2, 1193533200
- tz.transition 2008, 3, :o3, 1206838800
- tz.transition 2008, 10, :o2, 1224982800
- tz.transition 2009, 3, :o3, 1238288400
- tz.transition 2009, 10, :o2, 1256432400
- tz.transition 2010, 3, :o3, 1269738000
- tz.transition 2010, 10, :o2, 1288486800
- tz.transition 2011, 3, :o3, 1301187600
- tz.transition 2011, 10, :o2, 1319936400
- tz.transition 2012, 3, :o3, 1332637200
- tz.transition 2012, 10, :o2, 1351386000
- tz.transition 2013, 3, :o3, 1364691600
- tz.transition 2013, 10, :o2, 1382835600
- tz.transition 2014, 3, :o3, 1396141200
- tz.transition 2014, 10, :o2, 1414285200
- tz.transition 2015, 3, :o3, 1427590800
- tz.transition 2015, 10, :o2, 1445734800
- tz.transition 2016, 3, :o3, 1459040400
- tz.transition 2016, 10, :o2, 1477789200
- tz.transition 2017, 3, :o3, 1490490000
- tz.transition 2017, 10, :o2, 1509238800
- tz.transition 2018, 3, :o3, 1521939600
- tz.transition 2018, 10, :o2, 1540688400
- tz.transition 2019, 3, :o3, 1553994000
- tz.transition 2019, 10, :o2, 1572138000
- tz.transition 2020, 3, :o3, 1585443600
- tz.transition 2020, 10, :o2, 1603587600
- tz.transition 2021, 3, :o3, 1616893200
- tz.transition 2021, 10, :o2, 1635642000
- tz.transition 2022, 3, :o3, 1648342800
- tz.transition 2022, 10, :o2, 1667091600
- tz.transition 2023, 3, :o3, 1679792400
- tz.transition 2023, 10, :o2, 1698541200
- tz.transition 2024, 3, :o3, 1711846800
- tz.transition 2024, 10, :o2, 1729990800
- tz.transition 2025, 3, :o3, 1743296400
- tz.transition 2025, 10, :o2, 1761440400
- tz.transition 2026, 3, :o3, 1774746000
- tz.transition 2026, 10, :o2, 1792890000
- tz.transition 2027, 3, :o3, 1806195600
- tz.transition 2027, 10, :o2, 1824944400
- tz.transition 2028, 3, :o3, 1837645200
- tz.transition 2028, 10, :o2, 1856394000
- tz.transition 2029, 3, :o3, 1869094800
- tz.transition 2029, 10, :o2, 1887843600
- tz.transition 2030, 3, :o3, 1901149200
- tz.transition 2030, 10, :o2, 1919293200
- tz.transition 2031, 3, :o3, 1932598800
- tz.transition 2031, 10, :o2, 1950742800
- tz.transition 2032, 3, :o3, 1964048400
- tz.transition 2032, 10, :o2, 1982797200
- tz.transition 2033, 3, :o3, 1995498000
- tz.transition 2033, 10, :o2, 2014246800
- tz.transition 2034, 3, :o3, 2026947600
- tz.transition 2034, 10, :o2, 2045696400
- tz.transition 2035, 3, :o3, 2058397200
- tz.transition 2035, 10, :o2, 2077146000
- tz.transition 2036, 3, :o3, 2090451600
- tz.transition 2036, 10, :o2, 2108595600
- tz.transition 2037, 3, :o3, 2121901200
- tz.transition 2037, 10, :o2, 2140045200
- tz.transition 2038, 3, :o3, 59172253, 24
- tz.transition 2038, 10, :o2, 59177461, 24
- tz.transition 2039, 3, :o3, 59180989, 24
- tz.transition 2039, 10, :o2, 59186197, 24
- tz.transition 2040, 3, :o3, 59189725, 24
- tz.transition 2040, 10, :o2, 59194933, 24
- tz.transition 2041, 3, :o3, 59198629, 24
- tz.transition 2041, 10, :o2, 59203669, 24
- tz.transition 2042, 3, :o3, 59207365, 24
- tz.transition 2042, 10, :o2, 59212405, 24
- tz.transition 2043, 3, :o3, 59216101, 24
- tz.transition 2043, 10, :o2, 59221141, 24
- tz.transition 2044, 3, :o3, 59224837, 24
- tz.transition 2044, 10, :o2, 59230045, 24
- tz.transition 2045, 3, :o3, 59233573, 24
- tz.transition 2045, 10, :o2, 59238781, 24
- tz.transition 2046, 3, :o3, 59242309, 24
- tz.transition 2046, 10, :o2, 59247517, 24
- tz.transition 2047, 3, :o3, 59251213, 24
- tz.transition 2047, 10, :o2, 59256253, 24
- tz.transition 2048, 3, :o3, 59259949, 24
- tz.transition 2048, 10, :o2, 59264989, 24
- tz.transition 2049, 3, :o3, 59268685, 24
- tz.transition 2049, 10, :o2, 59273893, 24
- tz.transition 2050, 3, :o3, 59277421, 24
- tz.transition 2050, 10, :o2, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Dublin.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Dublin.rb
deleted file mode 100644
index 0560bb5436..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Dublin.rb
+++ /dev/null
@@ -1,276 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Dublin
- include TimezoneDefinition
-
- timezone 'Europe/Dublin' do |tz|
- tz.offset :o0, -1500, 0, :LMT
- tz.offset :o1, -1521, 0, :DMT
- tz.offset :o2, -1521, 3600, :IST
- tz.offset :o3, 0, 0, :GMT
- tz.offset :o4, 0, 3600, :BST
- tz.offset :o5, 0, 3600, :IST
- tz.offset :o6, 3600, 0, :IST
-
- tz.transition 1880, 8, :o1, 693483701, 288
- tz.transition 1916, 5, :o2, 7747214723, 3200
- tz.transition 1916, 10, :o3, 7747640323, 3200
- tz.transition 1917, 4, :o4, 29055919, 12
- tz.transition 1917, 9, :o3, 29057863, 12
- tz.transition 1918, 3, :o4, 29060119, 12
- tz.transition 1918, 9, :o3, 29062399, 12
- tz.transition 1919, 3, :o4, 29064571, 12
- tz.transition 1919, 9, :o3, 29066767, 12
- tz.transition 1920, 3, :o4, 29068939, 12
- tz.transition 1920, 10, :o3, 29071471, 12
- tz.transition 1921, 4, :o4, 29073391, 12
- tz.transition 1921, 10, :o3, 29075587, 12
- tz.transition 1922, 3, :o5, 29077675, 12
- tz.transition 1922, 10, :o3, 29080027, 12
- tz.transition 1923, 4, :o5, 29082379, 12
- tz.transition 1923, 9, :o3, 29084143, 12
- tz.transition 1924, 4, :o5, 29086663, 12
- tz.transition 1924, 9, :o3, 29088595, 12
- tz.transition 1925, 4, :o5, 29091115, 12
- tz.transition 1925, 10, :o3, 29093131, 12
- tz.transition 1926, 4, :o5, 29095483, 12
- tz.transition 1926, 10, :o3, 29097499, 12
- tz.transition 1927, 4, :o5, 29099767, 12
- tz.transition 1927, 10, :o3, 29101867, 12
- tz.transition 1928, 4, :o5, 29104303, 12
- tz.transition 1928, 10, :o3, 29106319, 12
- tz.transition 1929, 4, :o5, 29108671, 12
- tz.transition 1929, 10, :o3, 29110687, 12
- tz.transition 1930, 4, :o5, 29112955, 12
- tz.transition 1930, 10, :o3, 29115055, 12
- tz.transition 1931, 4, :o5, 29117407, 12
- tz.transition 1931, 10, :o3, 29119423, 12
- tz.transition 1932, 4, :o5, 29121775, 12
- tz.transition 1932, 10, :o3, 29123791, 12
- tz.transition 1933, 4, :o5, 29126059, 12
- tz.transition 1933, 10, :o3, 29128243, 12
- tz.transition 1934, 4, :o5, 29130595, 12
- tz.transition 1934, 10, :o3, 29132611, 12
- tz.transition 1935, 4, :o5, 29134879, 12
- tz.transition 1935, 10, :o3, 29136979, 12
- tz.transition 1936, 4, :o5, 29139331, 12
- tz.transition 1936, 10, :o3, 29141347, 12
- tz.transition 1937, 4, :o5, 29143699, 12
- tz.transition 1937, 10, :o3, 29145715, 12
- tz.transition 1938, 4, :o5, 29147983, 12
- tz.transition 1938, 10, :o3, 29150083, 12
- tz.transition 1939, 4, :o5, 29152435, 12
- tz.transition 1939, 11, :o3, 29155039, 12
- tz.transition 1940, 2, :o5, 29156215, 12
- tz.transition 1946, 10, :o3, 58370389, 24
- tz.transition 1947, 3, :o5, 29187127, 12
- tz.transition 1947, 11, :o3, 58379797, 24
- tz.transition 1948, 4, :o5, 29191915, 12
- tz.transition 1948, 10, :o3, 29194267, 12
- tz.transition 1949, 4, :o5, 29196115, 12
- tz.transition 1949, 10, :o3, 29198635, 12
- tz.transition 1950, 4, :o5, 29200651, 12
- tz.transition 1950, 10, :o3, 29202919, 12
- tz.transition 1951, 4, :o5, 29205019, 12
- tz.transition 1951, 10, :o3, 29207287, 12
- tz.transition 1952, 4, :o5, 29209471, 12
- tz.transition 1952, 10, :o3, 29211739, 12
- tz.transition 1953, 4, :o5, 29213839, 12
- tz.transition 1953, 10, :o3, 29215855, 12
- tz.transition 1954, 4, :o5, 29218123, 12
- tz.transition 1954, 10, :o3, 29220223, 12
- tz.transition 1955, 4, :o5, 29222575, 12
- tz.transition 1955, 10, :o3, 29224591, 12
- tz.transition 1956, 4, :o5, 29227027, 12
- tz.transition 1956, 10, :o3, 29229043, 12
- tz.transition 1957, 4, :o5, 29231311, 12
- tz.transition 1957, 10, :o3, 29233411, 12
- tz.transition 1958, 4, :o5, 29235763, 12
- tz.transition 1958, 10, :o3, 29237779, 12
- tz.transition 1959, 4, :o5, 29240131, 12
- tz.transition 1959, 10, :o3, 29242147, 12
- tz.transition 1960, 4, :o5, 29244415, 12
- tz.transition 1960, 10, :o3, 29246515, 12
- tz.transition 1961, 3, :o5, 29248615, 12
- tz.transition 1961, 10, :o3, 29251219, 12
- tz.transition 1962, 3, :o5, 29252983, 12
- tz.transition 1962, 10, :o3, 29255587, 12
- tz.transition 1963, 3, :o5, 29257435, 12
- tz.transition 1963, 10, :o3, 29259955, 12
- tz.transition 1964, 3, :o5, 29261719, 12
- tz.transition 1964, 10, :o3, 29264323, 12
- tz.transition 1965, 3, :o5, 29266087, 12
- tz.transition 1965, 10, :o3, 29268691, 12
- tz.transition 1966, 3, :o5, 29270455, 12
- tz.transition 1966, 10, :o3, 29273059, 12
- tz.transition 1967, 3, :o5, 29274823, 12
- tz.transition 1967, 10, :o3, 29277511, 12
- tz.transition 1968, 2, :o5, 29278855, 12
- tz.transition 1968, 10, :o6, 58563755, 24
- tz.transition 1971, 10, :o3, 57722400
- tz.transition 1972, 3, :o5, 69818400
- tz.transition 1972, 10, :o3, 89172000
- tz.transition 1973, 3, :o5, 101268000
- tz.transition 1973, 10, :o3, 120621600
- tz.transition 1974, 3, :o5, 132717600
- tz.transition 1974, 10, :o3, 152071200
- tz.transition 1975, 3, :o5, 164167200
- tz.transition 1975, 10, :o3, 183520800
- tz.transition 1976, 3, :o5, 196221600
- tz.transition 1976, 10, :o3, 214970400
- tz.transition 1977, 3, :o5, 227671200
- tz.transition 1977, 10, :o3, 246420000
- tz.transition 1978, 3, :o5, 259120800
- tz.transition 1978, 10, :o3, 278474400
- tz.transition 1979, 3, :o5, 290570400
- tz.transition 1979, 10, :o3, 309924000
- tz.transition 1980, 3, :o5, 322020000
- tz.transition 1980, 10, :o3, 341373600
- tz.transition 1981, 3, :o5, 354675600
- tz.transition 1981, 10, :o3, 372819600
- tz.transition 1982, 3, :o5, 386125200
- tz.transition 1982, 10, :o3, 404269200
- tz.transition 1983, 3, :o5, 417574800
- tz.transition 1983, 10, :o3, 435718800
- tz.transition 1984, 3, :o5, 449024400
- tz.transition 1984, 10, :o3, 467773200
- tz.transition 1985, 3, :o5, 481078800
- tz.transition 1985, 10, :o3, 499222800
- tz.transition 1986, 3, :o5, 512528400
- tz.transition 1986, 10, :o3, 530672400
- tz.transition 1987, 3, :o5, 543978000
- tz.transition 1987, 10, :o3, 562122000
- tz.transition 1988, 3, :o5, 575427600
- tz.transition 1988, 10, :o3, 593571600
- tz.transition 1989, 3, :o5, 606877200
- tz.transition 1989, 10, :o3, 625626000
- tz.transition 1990, 3, :o5, 638326800
- tz.transition 1990, 10, :o3, 657075600
- tz.transition 1991, 3, :o5, 670381200
- tz.transition 1991, 10, :o3, 688525200
- tz.transition 1992, 3, :o5, 701830800
- tz.transition 1992, 10, :o3, 719974800
- tz.transition 1993, 3, :o5, 733280400
- tz.transition 1993, 10, :o3, 751424400
- tz.transition 1994, 3, :o5, 764730000
- tz.transition 1994, 10, :o3, 782874000
- tz.transition 1995, 3, :o5, 796179600
- tz.transition 1995, 10, :o3, 814323600
- tz.transition 1996, 3, :o5, 828234000
- tz.transition 1996, 10, :o3, 846378000
- tz.transition 1997, 3, :o5, 859683600
- tz.transition 1997, 10, :o3, 877827600
- tz.transition 1998, 3, :o5, 891133200
- tz.transition 1998, 10, :o3, 909277200
- tz.transition 1999, 3, :o5, 922582800
- tz.transition 1999, 10, :o3, 941331600
- tz.transition 2000, 3, :o5, 954032400
- tz.transition 2000, 10, :o3, 972781200
- tz.transition 2001, 3, :o5, 985482000
- tz.transition 2001, 10, :o3, 1004230800
- tz.transition 2002, 3, :o5, 1017536400
- tz.transition 2002, 10, :o3, 1035680400
- tz.transition 2003, 3, :o5, 1048986000
- tz.transition 2003, 10, :o3, 1067130000
- tz.transition 2004, 3, :o5, 1080435600
- tz.transition 2004, 10, :o3, 1099184400
- tz.transition 2005, 3, :o5, 1111885200
- tz.transition 2005, 10, :o3, 1130634000
- tz.transition 2006, 3, :o5, 1143334800
- tz.transition 2006, 10, :o3, 1162083600
- tz.transition 2007, 3, :o5, 1174784400
- tz.transition 2007, 10, :o3, 1193533200
- tz.transition 2008, 3, :o5, 1206838800
- tz.transition 2008, 10, :o3, 1224982800
- tz.transition 2009, 3, :o5, 1238288400
- tz.transition 2009, 10, :o3, 1256432400
- tz.transition 2010, 3, :o5, 1269738000
- tz.transition 2010, 10, :o3, 1288486800
- tz.transition 2011, 3, :o5, 1301187600
- tz.transition 2011, 10, :o3, 1319936400
- tz.transition 2012, 3, :o5, 1332637200
- tz.transition 2012, 10, :o3, 1351386000
- tz.transition 2013, 3, :o5, 1364691600
- tz.transition 2013, 10, :o3, 1382835600
- tz.transition 2014, 3, :o5, 1396141200
- tz.transition 2014, 10, :o3, 1414285200
- tz.transition 2015, 3, :o5, 1427590800
- tz.transition 2015, 10, :o3, 1445734800
- tz.transition 2016, 3, :o5, 1459040400
- tz.transition 2016, 10, :o3, 1477789200
- tz.transition 2017, 3, :o5, 1490490000
- tz.transition 2017, 10, :o3, 1509238800
- tz.transition 2018, 3, :o5, 1521939600
- tz.transition 2018, 10, :o3, 1540688400
- tz.transition 2019, 3, :o5, 1553994000
- tz.transition 2019, 10, :o3, 1572138000
- tz.transition 2020, 3, :o5, 1585443600
- tz.transition 2020, 10, :o3, 1603587600
- tz.transition 2021, 3, :o5, 1616893200
- tz.transition 2021, 10, :o3, 1635642000
- tz.transition 2022, 3, :o5, 1648342800
- tz.transition 2022, 10, :o3, 1667091600
- tz.transition 2023, 3, :o5, 1679792400
- tz.transition 2023, 10, :o3, 1698541200
- tz.transition 2024, 3, :o5, 1711846800
- tz.transition 2024, 10, :o3, 1729990800
- tz.transition 2025, 3, :o5, 1743296400
- tz.transition 2025, 10, :o3, 1761440400
- tz.transition 2026, 3, :o5, 1774746000
- tz.transition 2026, 10, :o3, 1792890000
- tz.transition 2027, 3, :o5, 1806195600
- tz.transition 2027, 10, :o3, 1824944400
- tz.transition 2028, 3, :o5, 1837645200
- tz.transition 2028, 10, :o3, 1856394000
- tz.transition 2029, 3, :o5, 1869094800
- tz.transition 2029, 10, :o3, 1887843600
- tz.transition 2030, 3, :o5, 1901149200
- tz.transition 2030, 10, :o3, 1919293200
- tz.transition 2031, 3, :o5, 1932598800
- tz.transition 2031, 10, :o3, 1950742800
- tz.transition 2032, 3, :o5, 1964048400
- tz.transition 2032, 10, :o3, 1982797200
- tz.transition 2033, 3, :o5, 1995498000
- tz.transition 2033, 10, :o3, 2014246800
- tz.transition 2034, 3, :o5, 2026947600
- tz.transition 2034, 10, :o3, 2045696400
- tz.transition 2035, 3, :o5, 2058397200
- tz.transition 2035, 10, :o3, 2077146000
- tz.transition 2036, 3, :o5, 2090451600
- tz.transition 2036, 10, :o3, 2108595600
- tz.transition 2037, 3, :o5, 2121901200
- tz.transition 2037, 10, :o3, 2140045200
- tz.transition 2038, 3, :o5, 59172253, 24
- tz.transition 2038, 10, :o3, 59177461, 24
- tz.transition 2039, 3, :o5, 59180989, 24
- tz.transition 2039, 10, :o3, 59186197, 24
- tz.transition 2040, 3, :o5, 59189725, 24
- tz.transition 2040, 10, :o3, 59194933, 24
- tz.transition 2041, 3, :o5, 59198629, 24
- tz.transition 2041, 10, :o3, 59203669, 24
- tz.transition 2042, 3, :o5, 59207365, 24
- tz.transition 2042, 10, :o3, 59212405, 24
- tz.transition 2043, 3, :o5, 59216101, 24
- tz.transition 2043, 10, :o3, 59221141, 24
- tz.transition 2044, 3, :o5, 59224837, 24
- tz.transition 2044, 10, :o3, 59230045, 24
- tz.transition 2045, 3, :o5, 59233573, 24
- tz.transition 2045, 10, :o3, 59238781, 24
- tz.transition 2046, 3, :o5, 59242309, 24
- tz.transition 2046, 10, :o3, 59247517, 24
- tz.transition 2047, 3, :o5, 59251213, 24
- tz.transition 2047, 10, :o3, 59256253, 24
- tz.transition 2048, 3, :o5, 59259949, 24
- tz.transition 2048, 10, :o3, 59264989, 24
- tz.transition 2049, 3, :o5, 59268685, 24
- tz.transition 2049, 10, :o3, 59273893, 24
- tz.transition 2050, 3, :o5, 59277421, 24
- tz.transition 2050, 10, :o3, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Helsinki.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Helsinki.rb
deleted file mode 100644
index 13a806bcc7..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Helsinki.rb
+++ /dev/null
@@ -1,163 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Helsinki
- include TimezoneDefinition
-
- timezone 'Europe/Helsinki' do |tz|
- tz.offset :o0, 5992, 0, :LMT
- tz.offset :o1, 5992, 0, :HMT
- tz.offset :o2, 7200, 0, :EET
- tz.offset :o3, 7200, 3600, :EEST
-
- tz.transition 1878, 5, :o1, 25997062651, 10800
- tz.transition 1921, 4, :o2, 26166352651, 10800
- tz.transition 1942, 4, :o3, 29165429, 12
- tz.transition 1942, 10, :o2, 19445083, 8
- tz.transition 1981, 3, :o3, 354675600
- tz.transition 1981, 9, :o2, 370400400
- tz.transition 1982, 3, :o3, 386125200
- tz.transition 1982, 9, :o2, 401850000
- tz.transition 1983, 3, :o3, 417574800
- tz.transition 1983, 9, :o2, 433299600
- tz.transition 1984, 3, :o3, 449024400
- tz.transition 1984, 9, :o2, 465354000
- tz.transition 1985, 3, :o3, 481078800
- tz.transition 1985, 9, :o2, 496803600
- tz.transition 1986, 3, :o3, 512528400
- tz.transition 1986, 9, :o2, 528253200
- tz.transition 1987, 3, :o3, 543978000
- tz.transition 1987, 9, :o2, 559702800
- tz.transition 1988, 3, :o3, 575427600
- tz.transition 1988, 9, :o2, 591152400
- tz.transition 1989, 3, :o3, 606877200
- tz.transition 1989, 9, :o2, 622602000
- tz.transition 1990, 3, :o3, 638326800
- tz.transition 1990, 9, :o2, 654656400
- tz.transition 1991, 3, :o3, 670381200
- tz.transition 1991, 9, :o2, 686106000
- tz.transition 1992, 3, :o3, 701830800
- tz.transition 1992, 9, :o2, 717555600
- tz.transition 1993, 3, :o3, 733280400
- tz.transition 1993, 9, :o2, 749005200
- tz.transition 1994, 3, :o3, 764730000
- tz.transition 1994, 9, :o2, 780454800
- tz.transition 1995, 3, :o3, 796179600
- tz.transition 1995, 9, :o2, 811904400
- tz.transition 1996, 3, :o3, 828234000
- tz.transition 1996, 10, :o2, 846378000
- tz.transition 1997, 3, :o3, 859683600
- tz.transition 1997, 10, :o2, 877827600
- tz.transition 1998, 3, :o3, 891133200
- tz.transition 1998, 10, :o2, 909277200
- tz.transition 1999, 3, :o3, 922582800
- tz.transition 1999, 10, :o2, 941331600
- tz.transition 2000, 3, :o3, 954032400
- tz.transition 2000, 10, :o2, 972781200
- tz.transition 2001, 3, :o3, 985482000
- tz.transition 2001, 10, :o2, 1004230800
- tz.transition 2002, 3, :o3, 1017536400
- tz.transition 2002, 10, :o2, 1035680400
- tz.transition 2003, 3, :o3, 1048986000
- tz.transition 2003, 10, :o2, 1067130000
- tz.transition 2004, 3, :o3, 1080435600
- tz.transition 2004, 10, :o2, 1099184400
- tz.transition 2005, 3, :o3, 1111885200
- tz.transition 2005, 10, :o2, 1130634000
- tz.transition 2006, 3, :o3, 1143334800
- tz.transition 2006, 10, :o2, 1162083600
- tz.transition 2007, 3, :o3, 1174784400
- tz.transition 2007, 10, :o2, 1193533200
- tz.transition 2008, 3, :o3, 1206838800
- tz.transition 2008, 10, :o2, 1224982800
- tz.transition 2009, 3, :o3, 1238288400
- tz.transition 2009, 10, :o2, 1256432400
- tz.transition 2010, 3, :o3, 1269738000
- tz.transition 2010, 10, :o2, 1288486800
- tz.transition 2011, 3, :o3, 1301187600
- tz.transition 2011, 10, :o2, 1319936400
- tz.transition 2012, 3, :o3, 1332637200
- tz.transition 2012, 10, :o2, 1351386000
- tz.transition 2013, 3, :o3, 1364691600
- tz.transition 2013, 10, :o2, 1382835600
- tz.transition 2014, 3, :o3, 1396141200
- tz.transition 2014, 10, :o2, 1414285200
- tz.transition 2015, 3, :o3, 1427590800
- tz.transition 2015, 10, :o2, 1445734800
- tz.transition 2016, 3, :o3, 1459040400
- tz.transition 2016, 10, :o2, 1477789200
- tz.transition 2017, 3, :o3, 1490490000
- tz.transition 2017, 10, :o2, 1509238800
- tz.transition 2018, 3, :o3, 1521939600
- tz.transition 2018, 10, :o2, 1540688400
- tz.transition 2019, 3, :o3, 1553994000
- tz.transition 2019, 10, :o2, 1572138000
- tz.transition 2020, 3, :o3, 1585443600
- tz.transition 2020, 10, :o2, 1603587600
- tz.transition 2021, 3, :o3, 1616893200
- tz.transition 2021, 10, :o2, 1635642000
- tz.transition 2022, 3, :o3, 1648342800
- tz.transition 2022, 10, :o2, 1667091600
- tz.transition 2023, 3, :o3, 1679792400
- tz.transition 2023, 10, :o2, 1698541200
- tz.transition 2024, 3, :o3, 1711846800
- tz.transition 2024, 10, :o2, 1729990800
- tz.transition 2025, 3, :o3, 1743296400
- tz.transition 2025, 10, :o2, 1761440400
- tz.transition 2026, 3, :o3, 1774746000
- tz.transition 2026, 10, :o2, 1792890000
- tz.transition 2027, 3, :o3, 1806195600
- tz.transition 2027, 10, :o2, 1824944400
- tz.transition 2028, 3, :o3, 1837645200
- tz.transition 2028, 10, :o2, 1856394000
- tz.transition 2029, 3, :o3, 1869094800
- tz.transition 2029, 10, :o2, 1887843600
- tz.transition 2030, 3, :o3, 1901149200
- tz.transition 2030, 10, :o2, 1919293200
- tz.transition 2031, 3, :o3, 1932598800
- tz.transition 2031, 10, :o2, 1950742800
- tz.transition 2032, 3, :o3, 1964048400
- tz.transition 2032, 10, :o2, 1982797200
- tz.transition 2033, 3, :o3, 1995498000
- tz.transition 2033, 10, :o2, 2014246800
- tz.transition 2034, 3, :o3, 2026947600
- tz.transition 2034, 10, :o2, 2045696400
- tz.transition 2035, 3, :o3, 2058397200
- tz.transition 2035, 10, :o2, 2077146000
- tz.transition 2036, 3, :o3, 2090451600
- tz.transition 2036, 10, :o2, 2108595600
- tz.transition 2037, 3, :o3, 2121901200
- tz.transition 2037, 10, :o2, 2140045200
- tz.transition 2038, 3, :o3, 59172253, 24
- tz.transition 2038, 10, :o2, 59177461, 24
- tz.transition 2039, 3, :o3, 59180989, 24
- tz.transition 2039, 10, :o2, 59186197, 24
- tz.transition 2040, 3, :o3, 59189725, 24
- tz.transition 2040, 10, :o2, 59194933, 24
- tz.transition 2041, 3, :o3, 59198629, 24
- tz.transition 2041, 10, :o2, 59203669, 24
- tz.transition 2042, 3, :o3, 59207365, 24
- tz.transition 2042, 10, :o2, 59212405, 24
- tz.transition 2043, 3, :o3, 59216101, 24
- tz.transition 2043, 10, :o2, 59221141, 24
- tz.transition 2044, 3, :o3, 59224837, 24
- tz.transition 2044, 10, :o2, 59230045, 24
- tz.transition 2045, 3, :o3, 59233573, 24
- tz.transition 2045, 10, :o2, 59238781, 24
- tz.transition 2046, 3, :o3, 59242309, 24
- tz.transition 2046, 10, :o2, 59247517, 24
- tz.transition 2047, 3, :o3, 59251213, 24
- tz.transition 2047, 10, :o2, 59256253, 24
- tz.transition 2048, 3, :o3, 59259949, 24
- tz.transition 2048, 10, :o2, 59264989, 24
- tz.transition 2049, 3, :o3, 59268685, 24
- tz.transition 2049, 10, :o2, 59273893, 24
- tz.transition 2050, 3, :o3, 59277421, 24
- tz.transition 2050, 10, :o2, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Istanbul.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Istanbul.rb
deleted file mode 100644
index 8306c47536..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Istanbul.rb
+++ /dev/null
@@ -1,218 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Istanbul
- include TimezoneDefinition
-
- timezone 'Europe/Istanbul' do |tz|
- tz.offset :o0, 6952, 0, :LMT
- tz.offset :o1, 7016, 0, :IMT
- tz.offset :o2, 7200, 0, :EET
- tz.offset :o3, 7200, 3600, :EEST
- tz.offset :o4, 10800, 3600, :TRST
- tz.offset :o5, 10800, 0, :TRT
-
- tz.transition 1879, 12, :o1, 26003326531, 10800
- tz.transition 1910, 9, :o2, 26124610523, 10800
- tz.transition 1916, 4, :o3, 29051813, 12
- tz.transition 1916, 9, :o2, 19369099, 8
- tz.transition 1920, 3, :o3, 29068937, 12
- tz.transition 1920, 10, :o2, 19380979, 8
- tz.transition 1921, 4, :o3, 29073389, 12
- tz.transition 1921, 10, :o2, 19383723, 8
- tz.transition 1922, 3, :o3, 29077673, 12
- tz.transition 1922, 10, :o2, 19386683, 8
- tz.transition 1924, 5, :o3, 29087021, 12
- tz.transition 1924, 9, :o2, 19392475, 8
- tz.transition 1925, 4, :o3, 29091257, 12
- tz.transition 1925, 9, :o2, 19395395, 8
- tz.transition 1940, 6, :o3, 29157725, 12
- tz.transition 1940, 10, :o2, 19439259, 8
- tz.transition 1940, 11, :o3, 29159573, 12
- tz.transition 1941, 9, :o2, 19442067, 8
- tz.transition 1942, 3, :o3, 29165405, 12
- tz.transition 1942, 10, :o2, 19445315, 8
- tz.transition 1945, 4, :o3, 29178569, 12
- tz.transition 1945, 10, :o2, 19453891, 8
- tz.transition 1946, 5, :o3, 29183669, 12
- tz.transition 1946, 9, :o2, 19456755, 8
- tz.transition 1947, 4, :o3, 29187545, 12
- tz.transition 1947, 10, :o2, 19459707, 8
- tz.transition 1948, 4, :o3, 29191913, 12
- tz.transition 1948, 10, :o2, 19462619, 8
- tz.transition 1949, 4, :o3, 29196197, 12
- tz.transition 1949, 10, :o2, 19465531, 8
- tz.transition 1950, 4, :o3, 29200685, 12
- tz.transition 1950, 10, :o2, 19468499, 8
- tz.transition 1951, 4, :o3, 29205101, 12
- tz.transition 1951, 10, :o2, 19471419, 8
- tz.transition 1962, 7, :o3, 29254325, 12
- tz.transition 1962, 10, :o2, 19503563, 8
- tz.transition 1964, 5, :o3, 29262365, 12
- tz.transition 1964, 9, :o2, 19509355, 8
- tz.transition 1970, 5, :o3, 10533600
- tz.transition 1970, 10, :o2, 23835600
- tz.transition 1971, 5, :o3, 41983200
- tz.transition 1971, 10, :o2, 55285200
- tz.transition 1972, 5, :o3, 74037600
- tz.transition 1972, 10, :o2, 87339600
- tz.transition 1973, 6, :o3, 107910000
- tz.transition 1973, 11, :o2, 121219200
- tz.transition 1974, 3, :o3, 133920000
- tz.transition 1974, 11, :o2, 152676000
- tz.transition 1975, 3, :o3, 165362400
- tz.transition 1975, 10, :o2, 183502800
- tz.transition 1976, 5, :o3, 202428000
- tz.transition 1976, 10, :o2, 215557200
- tz.transition 1977, 4, :o3, 228866400
- tz.transition 1977, 10, :o2, 245797200
- tz.transition 1978, 4, :o3, 260316000
- tz.transition 1978, 10, :o4, 277246800
- tz.transition 1979, 10, :o5, 308779200
- tz.transition 1980, 4, :o4, 323827200
- tz.transition 1980, 10, :o5, 340228800
- tz.transition 1981, 3, :o4, 354672000
- tz.transition 1981, 10, :o5, 371678400
- tz.transition 1982, 3, :o4, 386121600
- tz.transition 1982, 10, :o5, 403128000
- tz.transition 1983, 7, :o4, 428446800
- tz.transition 1983, 10, :o5, 433886400
- tz.transition 1985, 4, :o3, 482792400
- tz.transition 1985, 9, :o2, 496702800
- tz.transition 1986, 3, :o3, 512524800
- tz.transition 1986, 9, :o2, 528249600
- tz.transition 1987, 3, :o3, 543974400
- tz.transition 1987, 9, :o2, 559699200
- tz.transition 1988, 3, :o3, 575424000
- tz.transition 1988, 9, :o2, 591148800
- tz.transition 1989, 3, :o3, 606873600
- tz.transition 1989, 9, :o2, 622598400
- tz.transition 1990, 3, :o3, 638323200
- tz.transition 1990, 9, :o2, 654652800
- tz.transition 1991, 3, :o3, 670374000
- tz.transition 1991, 9, :o2, 686098800
- tz.transition 1992, 3, :o3, 701823600
- tz.transition 1992, 9, :o2, 717548400
- tz.transition 1993, 3, :o3, 733273200
- tz.transition 1993, 9, :o2, 748998000
- tz.transition 1994, 3, :o3, 764722800
- tz.transition 1994, 9, :o2, 780447600
- tz.transition 1995, 3, :o3, 796172400
- tz.transition 1995, 9, :o2, 811897200
- tz.transition 1996, 3, :o3, 828226800
- tz.transition 1996, 10, :o2, 846370800
- tz.transition 1997, 3, :o3, 859676400
- tz.transition 1997, 10, :o2, 877820400
- tz.transition 1998, 3, :o3, 891126000
- tz.transition 1998, 10, :o2, 909270000
- tz.transition 1999, 3, :o3, 922575600
- tz.transition 1999, 10, :o2, 941324400
- tz.transition 2000, 3, :o3, 954025200
- tz.transition 2000, 10, :o2, 972774000
- tz.transition 2001, 3, :o3, 985474800
- tz.transition 2001, 10, :o2, 1004223600
- tz.transition 2002, 3, :o3, 1017529200
- tz.transition 2002, 10, :o2, 1035673200
- tz.transition 2003, 3, :o3, 1048978800
- tz.transition 2003, 10, :o2, 1067122800
- tz.transition 2004, 3, :o3, 1080428400
- tz.transition 2004, 10, :o2, 1099177200
- tz.transition 2005, 3, :o3, 1111878000
- tz.transition 2005, 10, :o2, 1130626800
- tz.transition 2006, 3, :o3, 1143327600
- tz.transition 2006, 10, :o2, 1162076400
- tz.transition 2007, 3, :o3, 1174784400
- tz.transition 2007, 10, :o2, 1193533200
- tz.transition 2008, 3, :o3, 1206838800
- tz.transition 2008, 10, :o2, 1224982800
- tz.transition 2009, 3, :o3, 1238288400
- tz.transition 2009, 10, :o2, 1256432400
- tz.transition 2010, 3, :o3, 1269738000
- tz.transition 2010, 10, :o2, 1288486800
- tz.transition 2011, 3, :o3, 1301187600
- tz.transition 2011, 10, :o2, 1319936400
- tz.transition 2012, 3, :o3, 1332637200
- tz.transition 2012, 10, :o2, 1351386000
- tz.transition 2013, 3, :o3, 1364691600
- tz.transition 2013, 10, :o2, 1382835600
- tz.transition 2014, 3, :o3, 1396141200
- tz.transition 2014, 10, :o2, 1414285200
- tz.transition 2015, 3, :o3, 1427590800
- tz.transition 2015, 10, :o2, 1445734800
- tz.transition 2016, 3, :o3, 1459040400
- tz.transition 2016, 10, :o2, 1477789200
- tz.transition 2017, 3, :o3, 1490490000
- tz.transition 2017, 10, :o2, 1509238800
- tz.transition 2018, 3, :o3, 1521939600
- tz.transition 2018, 10, :o2, 1540688400
- tz.transition 2019, 3, :o3, 1553994000
- tz.transition 2019, 10, :o2, 1572138000
- tz.transition 2020, 3, :o3, 1585443600
- tz.transition 2020, 10, :o2, 1603587600
- tz.transition 2021, 3, :o3, 1616893200
- tz.transition 2021, 10, :o2, 1635642000
- tz.transition 2022, 3, :o3, 1648342800
- tz.transition 2022, 10, :o2, 1667091600
- tz.transition 2023, 3, :o3, 1679792400
- tz.transition 2023, 10, :o2, 1698541200
- tz.transition 2024, 3, :o3, 1711846800
- tz.transition 2024, 10, :o2, 1729990800
- tz.transition 2025, 3, :o3, 1743296400
- tz.transition 2025, 10, :o2, 1761440400
- tz.transition 2026, 3, :o3, 1774746000
- tz.transition 2026, 10, :o2, 1792890000
- tz.transition 2027, 3, :o3, 1806195600
- tz.transition 2027, 10, :o2, 1824944400
- tz.transition 2028, 3, :o3, 1837645200
- tz.transition 2028, 10, :o2, 1856394000
- tz.transition 2029, 3, :o3, 1869094800
- tz.transition 2029, 10, :o2, 1887843600
- tz.transition 2030, 3, :o3, 1901149200
- tz.transition 2030, 10, :o2, 1919293200
- tz.transition 2031, 3, :o3, 1932598800
- tz.transition 2031, 10, :o2, 1950742800
- tz.transition 2032, 3, :o3, 1964048400
- tz.transition 2032, 10, :o2, 1982797200
- tz.transition 2033, 3, :o3, 1995498000
- tz.transition 2033, 10, :o2, 2014246800
- tz.transition 2034, 3, :o3, 2026947600
- tz.transition 2034, 10, :o2, 2045696400
- tz.transition 2035, 3, :o3, 2058397200
- tz.transition 2035, 10, :o2, 2077146000
- tz.transition 2036, 3, :o3, 2090451600
- tz.transition 2036, 10, :o2, 2108595600
- tz.transition 2037, 3, :o3, 2121901200
- tz.transition 2037, 10, :o2, 2140045200
- tz.transition 2038, 3, :o3, 59172253, 24
- tz.transition 2038, 10, :o2, 59177461, 24
- tz.transition 2039, 3, :o3, 59180989, 24
- tz.transition 2039, 10, :o2, 59186197, 24
- tz.transition 2040, 3, :o3, 59189725, 24
- tz.transition 2040, 10, :o2, 59194933, 24
- tz.transition 2041, 3, :o3, 59198629, 24
- tz.transition 2041, 10, :o2, 59203669, 24
- tz.transition 2042, 3, :o3, 59207365, 24
- tz.transition 2042, 10, :o2, 59212405, 24
- tz.transition 2043, 3, :o3, 59216101, 24
- tz.transition 2043, 10, :o2, 59221141, 24
- tz.transition 2044, 3, :o3, 59224837, 24
- tz.transition 2044, 10, :o2, 59230045, 24
- tz.transition 2045, 3, :o3, 59233573, 24
- tz.transition 2045, 10, :o2, 59238781, 24
- tz.transition 2046, 3, :o3, 59242309, 24
- tz.transition 2046, 10, :o2, 59247517, 24
- tz.transition 2047, 3, :o3, 59251213, 24
- tz.transition 2047, 10, :o2, 59256253, 24
- tz.transition 2048, 3, :o3, 59259949, 24
- tz.transition 2048, 10, :o2, 59264989, 24
- tz.transition 2049, 3, :o3, 59268685, 24
- tz.transition 2049, 10, :o2, 59273893, 24
- tz.transition 2050, 3, :o3, 59277421, 24
- tz.transition 2050, 10, :o2, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Kiev.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Kiev.rb
deleted file mode 100644
index 513d3308be..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Kiev.rb
+++ /dev/null
@@ -1,168 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Kiev
- include TimezoneDefinition
-
- timezone 'Europe/Kiev' do |tz|
- tz.offset :o0, 7324, 0, :LMT
- tz.offset :o1, 7324, 0, :KMT
- tz.offset :o2, 7200, 0, :EET
- tz.offset :o3, 10800, 0, :MSK
- tz.offset :o4, 3600, 3600, :CEST
- tz.offset :o5, 3600, 0, :CET
- tz.offset :o6, 10800, 3600, :MSD
- tz.offset :o7, 7200, 3600, :EEST
-
- tz.transition 1879, 12, :o1, 52006652969, 21600
- tz.transition 1924, 5, :o2, 52356400169, 21600
- tz.transition 1930, 6, :o3, 29113781, 12
- tz.transition 1941, 9, :o4, 19442059, 8
- tz.transition 1942, 11, :o5, 58335973, 24
- tz.transition 1943, 3, :o4, 58339501, 24
- tz.transition 1943, 10, :o5, 58344037, 24
- tz.transition 1943, 11, :o3, 58344827, 24
- tz.transition 1981, 3, :o6, 354920400
- tz.transition 1981, 9, :o3, 370728000
- tz.transition 1982, 3, :o6, 386456400
- tz.transition 1982, 9, :o3, 402264000
- tz.transition 1983, 3, :o6, 417992400
- tz.transition 1983, 9, :o3, 433800000
- tz.transition 1984, 3, :o6, 449614800
- tz.transition 1984, 9, :o3, 465346800
- tz.transition 1985, 3, :o6, 481071600
- tz.transition 1985, 9, :o3, 496796400
- tz.transition 1986, 3, :o6, 512521200
- tz.transition 1986, 9, :o3, 528246000
- tz.transition 1987, 3, :o6, 543970800
- tz.transition 1987, 9, :o3, 559695600
- tz.transition 1988, 3, :o6, 575420400
- tz.transition 1988, 9, :o3, 591145200
- tz.transition 1989, 3, :o6, 606870000
- tz.transition 1989, 9, :o3, 622594800
- tz.transition 1990, 6, :o2, 646786800
- tz.transition 1992, 3, :o7, 701820000
- tz.transition 1992, 9, :o2, 717541200
- tz.transition 1993, 3, :o7, 733269600
- tz.transition 1993, 9, :o2, 748990800
- tz.transition 1994, 3, :o7, 764719200
- tz.transition 1994, 9, :o2, 780440400
- tz.transition 1995, 3, :o7, 796179600
- tz.transition 1995, 9, :o2, 811904400
- tz.transition 1996, 3, :o7, 828234000
- tz.transition 1996, 10, :o2, 846378000
- tz.transition 1997, 3, :o7, 859683600
- tz.transition 1997, 10, :o2, 877827600
- tz.transition 1998, 3, :o7, 891133200
- tz.transition 1998, 10, :o2, 909277200
- tz.transition 1999, 3, :o7, 922582800
- tz.transition 1999, 10, :o2, 941331600
- tz.transition 2000, 3, :o7, 954032400
- tz.transition 2000, 10, :o2, 972781200
- tz.transition 2001, 3, :o7, 985482000
- tz.transition 2001, 10, :o2, 1004230800
- tz.transition 2002, 3, :o7, 1017536400
- tz.transition 2002, 10, :o2, 1035680400
- tz.transition 2003, 3, :o7, 1048986000
- tz.transition 2003, 10, :o2, 1067130000
- tz.transition 2004, 3, :o7, 1080435600
- tz.transition 2004, 10, :o2, 1099184400
- tz.transition 2005, 3, :o7, 1111885200
- tz.transition 2005, 10, :o2, 1130634000
- tz.transition 2006, 3, :o7, 1143334800
- tz.transition 2006, 10, :o2, 1162083600
- tz.transition 2007, 3, :o7, 1174784400
- tz.transition 2007, 10, :o2, 1193533200
- tz.transition 2008, 3, :o7, 1206838800
- tz.transition 2008, 10, :o2, 1224982800
- tz.transition 2009, 3, :o7, 1238288400
- tz.transition 2009, 10, :o2, 1256432400
- tz.transition 2010, 3, :o7, 1269738000
- tz.transition 2010, 10, :o2, 1288486800
- tz.transition 2011, 3, :o7, 1301187600
- tz.transition 2011, 10, :o2, 1319936400
- tz.transition 2012, 3, :o7, 1332637200
- tz.transition 2012, 10, :o2, 1351386000
- tz.transition 2013, 3, :o7, 1364691600
- tz.transition 2013, 10, :o2, 1382835600
- tz.transition 2014, 3, :o7, 1396141200
- tz.transition 2014, 10, :o2, 1414285200
- tz.transition 2015, 3, :o7, 1427590800
- tz.transition 2015, 10, :o2, 1445734800
- tz.transition 2016, 3, :o7, 1459040400
- tz.transition 2016, 10, :o2, 1477789200
- tz.transition 2017, 3, :o7, 1490490000
- tz.transition 2017, 10, :o2, 1509238800
- tz.transition 2018, 3, :o7, 1521939600
- tz.transition 2018, 10, :o2, 1540688400
- tz.transition 2019, 3, :o7, 1553994000
- tz.transition 2019, 10, :o2, 1572138000
- tz.transition 2020, 3, :o7, 1585443600
- tz.transition 2020, 10, :o2, 1603587600
- tz.transition 2021, 3, :o7, 1616893200
- tz.transition 2021, 10, :o2, 1635642000
- tz.transition 2022, 3, :o7, 1648342800
- tz.transition 2022, 10, :o2, 1667091600
- tz.transition 2023, 3, :o7, 1679792400
- tz.transition 2023, 10, :o2, 1698541200
- tz.transition 2024, 3, :o7, 1711846800
- tz.transition 2024, 10, :o2, 1729990800
- tz.transition 2025, 3, :o7, 1743296400
- tz.transition 2025, 10, :o2, 1761440400
- tz.transition 2026, 3, :o7, 1774746000
- tz.transition 2026, 10, :o2, 1792890000
- tz.transition 2027, 3, :o7, 1806195600
- tz.transition 2027, 10, :o2, 1824944400
- tz.transition 2028, 3, :o7, 1837645200
- tz.transition 2028, 10, :o2, 1856394000
- tz.transition 2029, 3, :o7, 1869094800
- tz.transition 2029, 10, :o2, 1887843600
- tz.transition 2030, 3, :o7, 1901149200
- tz.transition 2030, 10, :o2, 1919293200
- tz.transition 2031, 3, :o7, 1932598800
- tz.transition 2031, 10, :o2, 1950742800
- tz.transition 2032, 3, :o7, 1964048400
- tz.transition 2032, 10, :o2, 1982797200
- tz.transition 2033, 3, :o7, 1995498000
- tz.transition 2033, 10, :o2, 2014246800
- tz.transition 2034, 3, :o7, 2026947600
- tz.transition 2034, 10, :o2, 2045696400
- tz.transition 2035, 3, :o7, 2058397200
- tz.transition 2035, 10, :o2, 2077146000
- tz.transition 2036, 3, :o7, 2090451600
- tz.transition 2036, 10, :o2, 2108595600
- tz.transition 2037, 3, :o7, 2121901200
- tz.transition 2037, 10, :o2, 2140045200
- tz.transition 2038, 3, :o7, 59172253, 24
- tz.transition 2038, 10, :o2, 59177461, 24
- tz.transition 2039, 3, :o7, 59180989, 24
- tz.transition 2039, 10, :o2, 59186197, 24
- tz.transition 2040, 3, :o7, 59189725, 24
- tz.transition 2040, 10, :o2, 59194933, 24
- tz.transition 2041, 3, :o7, 59198629, 24
- tz.transition 2041, 10, :o2, 59203669, 24
- tz.transition 2042, 3, :o7, 59207365, 24
- tz.transition 2042, 10, :o2, 59212405, 24
- tz.transition 2043, 3, :o7, 59216101, 24
- tz.transition 2043, 10, :o2, 59221141, 24
- tz.transition 2044, 3, :o7, 59224837, 24
- tz.transition 2044, 10, :o2, 59230045, 24
- tz.transition 2045, 3, :o7, 59233573, 24
- tz.transition 2045, 10, :o2, 59238781, 24
- tz.transition 2046, 3, :o7, 59242309, 24
- tz.transition 2046, 10, :o2, 59247517, 24
- tz.transition 2047, 3, :o7, 59251213, 24
- tz.transition 2047, 10, :o2, 59256253, 24
- tz.transition 2048, 3, :o7, 59259949, 24
- tz.transition 2048, 10, :o2, 59264989, 24
- tz.transition 2049, 3, :o7, 59268685, 24
- tz.transition 2049, 10, :o2, 59273893, 24
- tz.transition 2050, 3, :o7, 59277421, 24
- tz.transition 2050, 10, :o2, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Lisbon.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Lisbon.rb
deleted file mode 100644
index 1c6d2a3d30..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Lisbon.rb
+++ /dev/null
@@ -1,268 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Lisbon
- include TimezoneDefinition
-
- timezone 'Europe/Lisbon' do |tz|
- tz.offset :o0, -2192, 0, :LMT
- tz.offset :o1, 0, 0, :WET
- tz.offset :o2, 0, 3600, :WEST
- tz.offset :o3, 0, 7200, :WEMT
- tz.offset :o4, 3600, 0, :CET
- tz.offset :o5, 3600, 3600, :CEST
-
- tz.transition 1912, 1, :o1, 13064773637, 5400
- tz.transition 1916, 6, :o2, 58104779, 24
- tz.transition 1916, 11, :o1, 4842337, 2
- tz.transition 1917, 2, :o2, 58110923, 24
- tz.transition 1917, 10, :o1, 58116395, 24
- tz.transition 1918, 3, :o2, 58119707, 24
- tz.transition 1918, 10, :o1, 58125155, 24
- tz.transition 1919, 2, :o2, 58128443, 24
- tz.transition 1919, 10, :o1, 58133915, 24
- tz.transition 1920, 2, :o2, 58137227, 24
- tz.transition 1920, 10, :o1, 58142699, 24
- tz.transition 1921, 2, :o2, 58145987, 24
- tz.transition 1921, 10, :o1, 58151459, 24
- tz.transition 1924, 4, :o2, 58173419, 24
- tz.transition 1924, 10, :o1, 58177763, 24
- tz.transition 1926, 4, :o2, 58190963, 24
- tz.transition 1926, 10, :o1, 58194995, 24
- tz.transition 1927, 4, :o2, 58199531, 24
- tz.transition 1927, 10, :o1, 58203731, 24
- tz.transition 1928, 4, :o2, 58208435, 24
- tz.transition 1928, 10, :o1, 58212635, 24
- tz.transition 1929, 4, :o2, 58217339, 24
- tz.transition 1929, 10, :o1, 58221371, 24
- tz.transition 1931, 4, :o2, 58234811, 24
- tz.transition 1931, 10, :o1, 58238843, 24
- tz.transition 1932, 4, :o2, 58243211, 24
- tz.transition 1932, 10, :o1, 58247579, 24
- tz.transition 1934, 4, :o2, 58260851, 24
- tz.transition 1934, 10, :o1, 58265219, 24
- tz.transition 1935, 3, :o2, 58269419, 24
- tz.transition 1935, 10, :o1, 58273955, 24
- tz.transition 1936, 4, :o2, 58278659, 24
- tz.transition 1936, 10, :o1, 58282691, 24
- tz.transition 1937, 4, :o2, 58287059, 24
- tz.transition 1937, 10, :o1, 58291427, 24
- tz.transition 1938, 3, :o2, 58295627, 24
- tz.transition 1938, 10, :o1, 58300163, 24
- tz.transition 1939, 4, :o2, 58304867, 24
- tz.transition 1939, 11, :o1, 58310075, 24
- tz.transition 1940, 2, :o2, 58312427, 24
- tz.transition 1940, 10, :o1, 58317803, 24
- tz.transition 1941, 4, :o2, 58322171, 24
- tz.transition 1941, 10, :o1, 58326563, 24
- tz.transition 1942, 3, :o2, 58330403, 24
- tz.transition 1942, 4, :o3, 29165705, 12
- tz.transition 1942, 8, :o2, 29167049, 12
- tz.transition 1942, 10, :o1, 58335779, 24
- tz.transition 1943, 3, :o2, 58339139, 24
- tz.transition 1943, 4, :o3, 29169989, 12
- tz.transition 1943, 8, :o2, 29171585, 12
- tz.transition 1943, 10, :o1, 58344683, 24
- tz.transition 1944, 3, :o2, 58347875, 24
- tz.transition 1944, 4, :o3, 29174441, 12
- tz.transition 1944, 8, :o2, 29175953, 12
- tz.transition 1944, 10, :o1, 58353419, 24
- tz.transition 1945, 3, :o2, 58356611, 24
- tz.transition 1945, 4, :o3, 29178809, 12
- tz.transition 1945, 8, :o2, 29180321, 12
- tz.transition 1945, 10, :o1, 58362155, 24
- tz.transition 1946, 4, :o2, 58366019, 24
- tz.transition 1946, 10, :o1, 58370387, 24
- tz.transition 1947, 4, :o2, 29187379, 12
- tz.transition 1947, 10, :o1, 29189563, 12
- tz.transition 1948, 4, :o2, 29191747, 12
- tz.transition 1948, 10, :o1, 29193931, 12
- tz.transition 1949, 4, :o2, 29196115, 12
- tz.transition 1949, 10, :o1, 29198299, 12
- tz.transition 1951, 4, :o2, 29204851, 12
- tz.transition 1951, 10, :o1, 29207119, 12
- tz.transition 1952, 4, :o2, 29209303, 12
- tz.transition 1952, 10, :o1, 29211487, 12
- tz.transition 1953, 4, :o2, 29213671, 12
- tz.transition 1953, 10, :o1, 29215855, 12
- tz.transition 1954, 4, :o2, 29218039, 12
- tz.transition 1954, 10, :o1, 29220223, 12
- tz.transition 1955, 4, :o2, 29222407, 12
- tz.transition 1955, 10, :o1, 29224591, 12
- tz.transition 1956, 4, :o2, 29226775, 12
- tz.transition 1956, 10, :o1, 29229043, 12
- tz.transition 1957, 4, :o2, 29231227, 12
- tz.transition 1957, 10, :o1, 29233411, 12
- tz.transition 1958, 4, :o2, 29235595, 12
- tz.transition 1958, 10, :o1, 29237779, 12
- tz.transition 1959, 4, :o2, 29239963, 12
- tz.transition 1959, 10, :o1, 29242147, 12
- tz.transition 1960, 4, :o2, 29244331, 12
- tz.transition 1960, 10, :o1, 29246515, 12
- tz.transition 1961, 4, :o2, 29248699, 12
- tz.transition 1961, 10, :o1, 29250883, 12
- tz.transition 1962, 4, :o2, 29253067, 12
- tz.transition 1962, 10, :o1, 29255335, 12
- tz.transition 1963, 4, :o2, 29257519, 12
- tz.transition 1963, 10, :o1, 29259703, 12
- tz.transition 1964, 4, :o2, 29261887, 12
- tz.transition 1964, 10, :o1, 29264071, 12
- tz.transition 1965, 4, :o2, 29266255, 12
- tz.transition 1965, 10, :o1, 29268439, 12
- tz.transition 1966, 4, :o4, 29270623, 12
- tz.transition 1976, 9, :o1, 212544000
- tz.transition 1977, 3, :o2, 228268800
- tz.transition 1977, 9, :o1, 243993600
- tz.transition 1978, 4, :o2, 260323200
- tz.transition 1978, 10, :o1, 276048000
- tz.transition 1979, 4, :o2, 291772800
- tz.transition 1979, 9, :o1, 307501200
- tz.transition 1980, 3, :o2, 323222400
- tz.transition 1980, 9, :o1, 338950800
- tz.transition 1981, 3, :o2, 354675600
- tz.transition 1981, 9, :o1, 370400400
- tz.transition 1982, 3, :o2, 386125200
- tz.transition 1982, 9, :o1, 401850000
- tz.transition 1983, 3, :o2, 417578400
- tz.transition 1983, 9, :o1, 433299600
- tz.transition 1984, 3, :o2, 449024400
- tz.transition 1984, 9, :o1, 465354000
- tz.transition 1985, 3, :o2, 481078800
- tz.transition 1985, 9, :o1, 496803600
- tz.transition 1986, 3, :o2, 512528400
- tz.transition 1986, 9, :o1, 528253200
- tz.transition 1987, 3, :o2, 543978000
- tz.transition 1987, 9, :o1, 559702800
- tz.transition 1988, 3, :o2, 575427600
- tz.transition 1988, 9, :o1, 591152400
- tz.transition 1989, 3, :o2, 606877200
- tz.transition 1989, 9, :o1, 622602000
- tz.transition 1990, 3, :o2, 638326800
- tz.transition 1990, 9, :o1, 654656400
- tz.transition 1991, 3, :o2, 670381200
- tz.transition 1991, 9, :o1, 686106000
- tz.transition 1992, 3, :o2, 701830800
- tz.transition 1992, 9, :o4, 717555600
- tz.transition 1993, 3, :o5, 733280400
- tz.transition 1993, 9, :o4, 749005200
- tz.transition 1994, 3, :o5, 764730000
- tz.transition 1994, 9, :o4, 780454800
- tz.transition 1995, 3, :o5, 796179600
- tz.transition 1995, 9, :o4, 811904400
- tz.transition 1996, 3, :o2, 828234000
- tz.transition 1996, 10, :o1, 846378000
- tz.transition 1997, 3, :o2, 859683600
- tz.transition 1997, 10, :o1, 877827600
- tz.transition 1998, 3, :o2, 891133200
- tz.transition 1998, 10, :o1, 909277200
- tz.transition 1999, 3, :o2, 922582800
- tz.transition 1999, 10, :o1, 941331600
- tz.transition 2000, 3, :o2, 954032400
- tz.transition 2000, 10, :o1, 972781200
- tz.transition 2001, 3, :o2, 985482000
- tz.transition 2001, 10, :o1, 1004230800
- tz.transition 2002, 3, :o2, 1017536400
- tz.transition 2002, 10, :o1, 1035680400
- tz.transition 2003, 3, :o2, 1048986000
- tz.transition 2003, 10, :o1, 1067130000
- tz.transition 2004, 3, :o2, 1080435600
- tz.transition 2004, 10, :o1, 1099184400
- tz.transition 2005, 3, :o2, 1111885200
- tz.transition 2005, 10, :o1, 1130634000
- tz.transition 2006, 3, :o2, 1143334800
- tz.transition 2006, 10, :o1, 1162083600
- tz.transition 2007, 3, :o2, 1174784400
- tz.transition 2007, 10, :o1, 1193533200
- tz.transition 2008, 3, :o2, 1206838800
- tz.transition 2008, 10, :o1, 1224982800
- tz.transition 2009, 3, :o2, 1238288400
- tz.transition 2009, 10, :o1, 1256432400
- tz.transition 2010, 3, :o2, 1269738000
- tz.transition 2010, 10, :o1, 1288486800
- tz.transition 2011, 3, :o2, 1301187600
- tz.transition 2011, 10, :o1, 1319936400
- tz.transition 2012, 3, :o2, 1332637200
- tz.transition 2012, 10, :o1, 1351386000
- tz.transition 2013, 3, :o2, 1364691600
- tz.transition 2013, 10, :o1, 1382835600
- tz.transition 2014, 3, :o2, 1396141200
- tz.transition 2014, 10, :o1, 1414285200
- tz.transition 2015, 3, :o2, 1427590800
- tz.transition 2015, 10, :o1, 1445734800
- tz.transition 2016, 3, :o2, 1459040400
- tz.transition 2016, 10, :o1, 1477789200
- tz.transition 2017, 3, :o2, 1490490000
- tz.transition 2017, 10, :o1, 1509238800
- tz.transition 2018, 3, :o2, 1521939600
- tz.transition 2018, 10, :o1, 1540688400
- tz.transition 2019, 3, :o2, 1553994000
- tz.transition 2019, 10, :o1, 1572138000
- tz.transition 2020, 3, :o2, 1585443600
- tz.transition 2020, 10, :o1, 1603587600
- tz.transition 2021, 3, :o2, 1616893200
- tz.transition 2021, 10, :o1, 1635642000
- tz.transition 2022, 3, :o2, 1648342800
- tz.transition 2022, 10, :o1, 1667091600
- tz.transition 2023, 3, :o2, 1679792400
- tz.transition 2023, 10, :o1, 1698541200
- tz.transition 2024, 3, :o2, 1711846800
- tz.transition 2024, 10, :o1, 1729990800
- tz.transition 2025, 3, :o2, 1743296400
- tz.transition 2025, 10, :o1, 1761440400
- tz.transition 2026, 3, :o2, 1774746000
- tz.transition 2026, 10, :o1, 1792890000
- tz.transition 2027, 3, :o2, 1806195600
- tz.transition 2027, 10, :o1, 1824944400
- tz.transition 2028, 3, :o2, 1837645200
- tz.transition 2028, 10, :o1, 1856394000
- tz.transition 2029, 3, :o2, 1869094800
- tz.transition 2029, 10, :o1, 1887843600
- tz.transition 2030, 3, :o2, 1901149200
- tz.transition 2030, 10, :o1, 1919293200
- tz.transition 2031, 3, :o2, 1932598800
- tz.transition 2031, 10, :o1, 1950742800
- tz.transition 2032, 3, :o2, 1964048400
- tz.transition 2032, 10, :o1, 1982797200
- tz.transition 2033, 3, :o2, 1995498000
- tz.transition 2033, 10, :o1, 2014246800
- tz.transition 2034, 3, :o2, 2026947600
- tz.transition 2034, 10, :o1, 2045696400
- tz.transition 2035, 3, :o2, 2058397200
- tz.transition 2035, 10, :o1, 2077146000
- tz.transition 2036, 3, :o2, 2090451600
- tz.transition 2036, 10, :o1, 2108595600
- tz.transition 2037, 3, :o2, 2121901200
- tz.transition 2037, 10, :o1, 2140045200
- tz.transition 2038, 3, :o2, 59172253, 24
- tz.transition 2038, 10, :o1, 59177461, 24
- tz.transition 2039, 3, :o2, 59180989, 24
- tz.transition 2039, 10, :o1, 59186197, 24
- tz.transition 2040, 3, :o2, 59189725, 24
- tz.transition 2040, 10, :o1, 59194933, 24
- tz.transition 2041, 3, :o2, 59198629, 24
- tz.transition 2041, 10, :o1, 59203669, 24
- tz.transition 2042, 3, :o2, 59207365, 24
- tz.transition 2042, 10, :o1, 59212405, 24
- tz.transition 2043, 3, :o2, 59216101, 24
- tz.transition 2043, 10, :o1, 59221141, 24
- tz.transition 2044, 3, :o2, 59224837, 24
- tz.transition 2044, 10, :o1, 59230045, 24
- tz.transition 2045, 3, :o2, 59233573, 24
- tz.transition 2045, 10, :o1, 59238781, 24
- tz.transition 2046, 3, :o2, 59242309, 24
- tz.transition 2046, 10, :o1, 59247517, 24
- tz.transition 2047, 3, :o2, 59251213, 24
- tz.transition 2047, 10, :o1, 59256253, 24
- tz.transition 2048, 3, :o2, 59259949, 24
- tz.transition 2048, 10, :o1, 59264989, 24
- tz.transition 2049, 3, :o2, 59268685, 24
- tz.transition 2049, 10, :o1, 59273893, 24
- tz.transition 2050, 3, :o2, 59277421, 24
- tz.transition 2050, 10, :o1, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Ljubljana.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Ljubljana.rb
deleted file mode 100644
index a9828e6ef8..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Ljubljana.rb
+++ /dev/null
@@ -1,13 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Ljubljana
- include TimezoneDefinition
-
- linked_timezone 'Europe/Ljubljana', 'Europe/Belgrade'
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/London.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/London.rb
deleted file mode 100644
index 64ce41e900..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/London.rb
+++ /dev/null
@@ -1,288 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module London
- include TimezoneDefinition
-
- timezone 'Europe/London' do |tz|
- tz.offset :o0, -75, 0, :LMT
- tz.offset :o1, 0, 0, :GMT
- tz.offset :o2, 0, 3600, :BST
- tz.offset :o3, 0, 7200, :BDST
- tz.offset :o4, 3600, 0, :BST
-
- tz.transition 1847, 12, :o1, 2760187969, 1152
- tz.transition 1916, 5, :o2, 29052055, 12
- tz.transition 1916, 10, :o1, 29053651, 12
- tz.transition 1917, 4, :o2, 29055919, 12
- tz.transition 1917, 9, :o1, 29057863, 12
- tz.transition 1918, 3, :o2, 29060119, 12
- tz.transition 1918, 9, :o1, 29062399, 12
- tz.transition 1919, 3, :o2, 29064571, 12
- tz.transition 1919, 9, :o1, 29066767, 12
- tz.transition 1920, 3, :o2, 29068939, 12
- tz.transition 1920, 10, :o1, 29071471, 12
- tz.transition 1921, 4, :o2, 29073391, 12
- tz.transition 1921, 10, :o1, 29075587, 12
- tz.transition 1922, 3, :o2, 29077675, 12
- tz.transition 1922, 10, :o1, 29080027, 12
- tz.transition 1923, 4, :o2, 29082379, 12
- tz.transition 1923, 9, :o1, 29084143, 12
- tz.transition 1924, 4, :o2, 29086663, 12
- tz.transition 1924, 9, :o1, 29088595, 12
- tz.transition 1925, 4, :o2, 29091115, 12
- tz.transition 1925, 10, :o1, 29093131, 12
- tz.transition 1926, 4, :o2, 29095483, 12
- tz.transition 1926, 10, :o1, 29097499, 12
- tz.transition 1927, 4, :o2, 29099767, 12
- tz.transition 1927, 10, :o1, 29101867, 12
- tz.transition 1928, 4, :o2, 29104303, 12
- tz.transition 1928, 10, :o1, 29106319, 12
- tz.transition 1929, 4, :o2, 29108671, 12
- tz.transition 1929, 10, :o1, 29110687, 12
- tz.transition 1930, 4, :o2, 29112955, 12
- tz.transition 1930, 10, :o1, 29115055, 12
- tz.transition 1931, 4, :o2, 29117407, 12
- tz.transition 1931, 10, :o1, 29119423, 12
- tz.transition 1932, 4, :o2, 29121775, 12
- tz.transition 1932, 10, :o1, 29123791, 12
- tz.transition 1933, 4, :o2, 29126059, 12
- tz.transition 1933, 10, :o1, 29128243, 12
- tz.transition 1934, 4, :o2, 29130595, 12
- tz.transition 1934, 10, :o1, 29132611, 12
- tz.transition 1935, 4, :o2, 29134879, 12
- tz.transition 1935, 10, :o1, 29136979, 12
- tz.transition 1936, 4, :o2, 29139331, 12
- tz.transition 1936, 10, :o1, 29141347, 12
- tz.transition 1937, 4, :o2, 29143699, 12
- tz.transition 1937, 10, :o1, 29145715, 12
- tz.transition 1938, 4, :o2, 29147983, 12
- tz.transition 1938, 10, :o1, 29150083, 12
- tz.transition 1939, 4, :o2, 29152435, 12
- tz.transition 1939, 11, :o1, 29155039, 12
- tz.transition 1940, 2, :o2, 29156215, 12
- tz.transition 1941, 5, :o3, 58322845, 24
- tz.transition 1941, 8, :o2, 58325197, 24
- tz.transition 1942, 4, :o3, 58330909, 24
- tz.transition 1942, 8, :o2, 58333933, 24
- tz.transition 1943, 4, :o3, 58339645, 24
- tz.transition 1943, 8, :o2, 58342837, 24
- tz.transition 1944, 4, :o3, 58348381, 24
- tz.transition 1944, 9, :o2, 58352413, 24
- tz.transition 1945, 4, :o3, 58357141, 24
- tz.transition 1945, 7, :o2, 58359637, 24
- tz.transition 1945, 10, :o1, 29180827, 12
- tz.transition 1946, 4, :o2, 29183095, 12
- tz.transition 1946, 10, :o1, 29185195, 12
- tz.transition 1947, 3, :o2, 29187127, 12
- tz.transition 1947, 4, :o3, 58374925, 24
- tz.transition 1947, 8, :o2, 58377781, 24
- tz.transition 1947, 11, :o1, 29189899, 12
- tz.transition 1948, 3, :o2, 29191495, 12
- tz.transition 1948, 10, :o1, 29194267, 12
- tz.transition 1949, 4, :o2, 29196115, 12
- tz.transition 1949, 10, :o1, 29198635, 12
- tz.transition 1950, 4, :o2, 29200651, 12
- tz.transition 1950, 10, :o1, 29202919, 12
- tz.transition 1951, 4, :o2, 29205019, 12
- tz.transition 1951, 10, :o1, 29207287, 12
- tz.transition 1952, 4, :o2, 29209471, 12
- tz.transition 1952, 10, :o1, 29211739, 12
- tz.transition 1953, 4, :o2, 29213839, 12
- tz.transition 1953, 10, :o1, 29215855, 12
- tz.transition 1954, 4, :o2, 29218123, 12
- tz.transition 1954, 10, :o1, 29220223, 12
- tz.transition 1955, 4, :o2, 29222575, 12
- tz.transition 1955, 10, :o1, 29224591, 12
- tz.transition 1956, 4, :o2, 29227027, 12
- tz.transition 1956, 10, :o1, 29229043, 12
- tz.transition 1957, 4, :o2, 29231311, 12
- tz.transition 1957, 10, :o1, 29233411, 12
- tz.transition 1958, 4, :o2, 29235763, 12
- tz.transition 1958, 10, :o1, 29237779, 12
- tz.transition 1959, 4, :o2, 29240131, 12
- tz.transition 1959, 10, :o1, 29242147, 12
- tz.transition 1960, 4, :o2, 29244415, 12
- tz.transition 1960, 10, :o1, 29246515, 12
- tz.transition 1961, 3, :o2, 29248615, 12
- tz.transition 1961, 10, :o1, 29251219, 12
- tz.transition 1962, 3, :o2, 29252983, 12
- tz.transition 1962, 10, :o1, 29255587, 12
- tz.transition 1963, 3, :o2, 29257435, 12
- tz.transition 1963, 10, :o1, 29259955, 12
- tz.transition 1964, 3, :o2, 29261719, 12
- tz.transition 1964, 10, :o1, 29264323, 12
- tz.transition 1965, 3, :o2, 29266087, 12
- tz.transition 1965, 10, :o1, 29268691, 12
- tz.transition 1966, 3, :o2, 29270455, 12
- tz.transition 1966, 10, :o1, 29273059, 12
- tz.transition 1967, 3, :o2, 29274823, 12
- tz.transition 1967, 10, :o1, 29277511, 12
- tz.transition 1968, 2, :o2, 29278855, 12
- tz.transition 1968, 10, :o4, 58563755, 24
- tz.transition 1971, 10, :o1, 57722400
- tz.transition 1972, 3, :o2, 69818400
- tz.transition 1972, 10, :o1, 89172000
- tz.transition 1973, 3, :o2, 101268000
- tz.transition 1973, 10, :o1, 120621600
- tz.transition 1974, 3, :o2, 132717600
- tz.transition 1974, 10, :o1, 152071200
- tz.transition 1975, 3, :o2, 164167200
- tz.transition 1975, 10, :o1, 183520800
- tz.transition 1976, 3, :o2, 196221600
- tz.transition 1976, 10, :o1, 214970400
- tz.transition 1977, 3, :o2, 227671200
- tz.transition 1977, 10, :o1, 246420000
- tz.transition 1978, 3, :o2, 259120800
- tz.transition 1978, 10, :o1, 278474400
- tz.transition 1979, 3, :o2, 290570400
- tz.transition 1979, 10, :o1, 309924000
- tz.transition 1980, 3, :o2, 322020000
- tz.transition 1980, 10, :o1, 341373600
- tz.transition 1981, 3, :o2, 354675600
- tz.transition 1981, 10, :o1, 372819600
- tz.transition 1982, 3, :o2, 386125200
- tz.transition 1982, 10, :o1, 404269200
- tz.transition 1983, 3, :o2, 417574800
- tz.transition 1983, 10, :o1, 435718800
- tz.transition 1984, 3, :o2, 449024400
- tz.transition 1984, 10, :o1, 467773200
- tz.transition 1985, 3, :o2, 481078800
- tz.transition 1985, 10, :o1, 499222800
- tz.transition 1986, 3, :o2, 512528400
- tz.transition 1986, 10, :o1, 530672400
- tz.transition 1987, 3, :o2, 543978000
- tz.transition 1987, 10, :o1, 562122000
- tz.transition 1988, 3, :o2, 575427600
- tz.transition 1988, 10, :o1, 593571600
- tz.transition 1989, 3, :o2, 606877200
- tz.transition 1989, 10, :o1, 625626000
- tz.transition 1990, 3, :o2, 638326800
- tz.transition 1990, 10, :o1, 657075600
- tz.transition 1991, 3, :o2, 670381200
- tz.transition 1991, 10, :o1, 688525200
- tz.transition 1992, 3, :o2, 701830800
- tz.transition 1992, 10, :o1, 719974800
- tz.transition 1993, 3, :o2, 733280400
- tz.transition 1993, 10, :o1, 751424400
- tz.transition 1994, 3, :o2, 764730000
- tz.transition 1994, 10, :o1, 782874000
- tz.transition 1995, 3, :o2, 796179600
- tz.transition 1995, 10, :o1, 814323600
- tz.transition 1996, 3, :o2, 828234000
- tz.transition 1996, 10, :o1, 846378000
- tz.transition 1997, 3, :o2, 859683600
- tz.transition 1997, 10, :o1, 877827600
- tz.transition 1998, 3, :o2, 891133200
- tz.transition 1998, 10, :o1, 909277200
- tz.transition 1999, 3, :o2, 922582800
- tz.transition 1999, 10, :o1, 941331600
- tz.transition 2000, 3, :o2, 954032400
- tz.transition 2000, 10, :o1, 972781200
- tz.transition 2001, 3, :o2, 985482000
- tz.transition 2001, 10, :o1, 1004230800
- tz.transition 2002, 3, :o2, 1017536400
- tz.transition 2002, 10, :o1, 1035680400
- tz.transition 2003, 3, :o2, 1048986000
- tz.transition 2003, 10, :o1, 1067130000
- tz.transition 2004, 3, :o2, 1080435600
- tz.transition 2004, 10, :o1, 1099184400
- tz.transition 2005, 3, :o2, 1111885200
- tz.transition 2005, 10, :o1, 1130634000
- tz.transition 2006, 3, :o2, 1143334800
- tz.transition 2006, 10, :o1, 1162083600
- tz.transition 2007, 3, :o2, 1174784400
- tz.transition 2007, 10, :o1, 1193533200
- tz.transition 2008, 3, :o2, 1206838800
- tz.transition 2008, 10, :o1, 1224982800
- tz.transition 2009, 3, :o2, 1238288400
- tz.transition 2009, 10, :o1, 1256432400
- tz.transition 2010, 3, :o2, 1269738000
- tz.transition 2010, 10, :o1, 1288486800
- tz.transition 2011, 3, :o2, 1301187600
- tz.transition 2011, 10, :o1, 1319936400
- tz.transition 2012, 3, :o2, 1332637200
- tz.transition 2012, 10, :o1, 1351386000
- tz.transition 2013, 3, :o2, 1364691600
- tz.transition 2013, 10, :o1, 1382835600
- tz.transition 2014, 3, :o2, 1396141200
- tz.transition 2014, 10, :o1, 1414285200
- tz.transition 2015, 3, :o2, 1427590800
- tz.transition 2015, 10, :o1, 1445734800
- tz.transition 2016, 3, :o2, 1459040400
- tz.transition 2016, 10, :o1, 1477789200
- tz.transition 2017, 3, :o2, 1490490000
- tz.transition 2017, 10, :o1, 1509238800
- tz.transition 2018, 3, :o2, 1521939600
- tz.transition 2018, 10, :o1, 1540688400
- tz.transition 2019, 3, :o2, 1553994000
- tz.transition 2019, 10, :o1, 1572138000
- tz.transition 2020, 3, :o2, 1585443600
- tz.transition 2020, 10, :o1, 1603587600
- tz.transition 2021, 3, :o2, 1616893200
- tz.transition 2021, 10, :o1, 1635642000
- tz.transition 2022, 3, :o2, 1648342800
- tz.transition 2022, 10, :o1, 1667091600
- tz.transition 2023, 3, :o2, 1679792400
- tz.transition 2023, 10, :o1, 1698541200
- tz.transition 2024, 3, :o2, 1711846800
- tz.transition 2024, 10, :o1, 1729990800
- tz.transition 2025, 3, :o2, 1743296400
- tz.transition 2025, 10, :o1, 1761440400
- tz.transition 2026, 3, :o2, 1774746000
- tz.transition 2026, 10, :o1, 1792890000
- tz.transition 2027, 3, :o2, 1806195600
- tz.transition 2027, 10, :o1, 1824944400
- tz.transition 2028, 3, :o2, 1837645200
- tz.transition 2028, 10, :o1, 1856394000
- tz.transition 2029, 3, :o2, 1869094800
- tz.transition 2029, 10, :o1, 1887843600
- tz.transition 2030, 3, :o2, 1901149200
- tz.transition 2030, 10, :o1, 1919293200
- tz.transition 2031, 3, :o2, 1932598800
- tz.transition 2031, 10, :o1, 1950742800
- tz.transition 2032, 3, :o2, 1964048400
- tz.transition 2032, 10, :o1, 1982797200
- tz.transition 2033, 3, :o2, 1995498000
- tz.transition 2033, 10, :o1, 2014246800
- tz.transition 2034, 3, :o2, 2026947600
- tz.transition 2034, 10, :o1, 2045696400
- tz.transition 2035, 3, :o2, 2058397200
- tz.transition 2035, 10, :o1, 2077146000
- tz.transition 2036, 3, :o2, 2090451600
- tz.transition 2036, 10, :o1, 2108595600
- tz.transition 2037, 3, :o2, 2121901200
- tz.transition 2037, 10, :o1, 2140045200
- tz.transition 2038, 3, :o2, 59172253, 24
- tz.transition 2038, 10, :o1, 59177461, 24
- tz.transition 2039, 3, :o2, 59180989, 24
- tz.transition 2039, 10, :o1, 59186197, 24
- tz.transition 2040, 3, :o2, 59189725, 24
- tz.transition 2040, 10, :o1, 59194933, 24
- tz.transition 2041, 3, :o2, 59198629, 24
- tz.transition 2041, 10, :o1, 59203669, 24
- tz.transition 2042, 3, :o2, 59207365, 24
- tz.transition 2042, 10, :o1, 59212405, 24
- tz.transition 2043, 3, :o2, 59216101, 24
- tz.transition 2043, 10, :o1, 59221141, 24
- tz.transition 2044, 3, :o2, 59224837, 24
- tz.transition 2044, 10, :o1, 59230045, 24
- tz.transition 2045, 3, :o2, 59233573, 24
- tz.transition 2045, 10, :o1, 59238781, 24
- tz.transition 2046, 3, :o2, 59242309, 24
- tz.transition 2046, 10, :o1, 59247517, 24
- tz.transition 2047, 3, :o2, 59251213, 24
- tz.transition 2047, 10, :o1, 59256253, 24
- tz.transition 2048, 3, :o2, 59259949, 24
- tz.transition 2048, 10, :o1, 59264989, 24
- tz.transition 2049, 3, :o2, 59268685, 24
- tz.transition 2049, 10, :o1, 59273893, 24
- tz.transition 2050, 3, :o2, 59277421, 24
- tz.transition 2050, 10, :o1, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Madrid.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Madrid.rb
deleted file mode 100644
index 1fb568239a..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Madrid.rb
+++ /dev/null
@@ -1,211 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Madrid
- include TimezoneDefinition
-
- timezone 'Europe/Madrid' do |tz|
- tz.offset :o0, -884, 0, :LMT
- tz.offset :o1, 0, 0, :WET
- tz.offset :o2, 0, 3600, :WEST
- tz.offset :o3, 0, 7200, :WEMT
- tz.offset :o4, 3600, 0, :CET
- tz.offset :o5, 3600, 3600, :CEST
-
- tz.transition 1901, 1, :o1, 52172327021, 21600
- tz.transition 1917, 5, :o2, 58112507, 24
- tz.transition 1917, 10, :o1, 58116203, 24
- tz.transition 1918, 4, :o2, 58120787, 24
- tz.transition 1918, 10, :o1, 58124963, 24
- tz.transition 1919, 4, :o2, 58129307, 24
- tz.transition 1919, 10, :o1, 58133723, 24
- tz.transition 1924, 4, :o2, 58173419, 24
- tz.transition 1924, 10, :o1, 58177523, 24
- tz.transition 1926, 4, :o2, 58190963, 24
- tz.transition 1926, 10, :o1, 58194995, 24
- tz.transition 1927, 4, :o2, 58199531, 24
- tz.transition 1927, 10, :o1, 58203731, 24
- tz.transition 1928, 4, :o2, 58208435, 24
- tz.transition 1928, 10, :o1, 58212635, 24
- tz.transition 1929, 4, :o2, 58217339, 24
- tz.transition 1929, 10, :o1, 58221371, 24
- tz.transition 1937, 5, :o2, 58288235, 24
- tz.transition 1937, 10, :o1, 58291427, 24
- tz.transition 1938, 3, :o2, 58295531, 24
- tz.transition 1938, 10, :o1, 58300163, 24
- tz.transition 1939, 4, :o2, 58304867, 24
- tz.transition 1939, 10, :o1, 58309067, 24
- tz.transition 1940, 3, :o2, 58312931, 24
- tz.transition 1942, 5, :o3, 29165789, 12
- tz.transition 1942, 9, :o2, 29167253, 12
- tz.transition 1943, 4, :o3, 29169989, 12
- tz.transition 1943, 10, :o2, 29172017, 12
- tz.transition 1944, 4, :o3, 29174357, 12
- tz.transition 1944, 10, :o2, 29176493, 12
- tz.transition 1945, 4, :o3, 29178725, 12
- tz.transition 1945, 9, :o2, 58361483, 24
- tz.transition 1946, 4, :o3, 29183093, 12
- tz.transition 1946, 9, :o4, 29185121, 12
- tz.transition 1949, 4, :o5, 29196449, 12
- tz.transition 1949, 9, :o4, 58396547, 24
- tz.transition 1974, 4, :o5, 135122400
- tz.transition 1974, 10, :o4, 150246000
- tz.transition 1975, 4, :o5, 167176800
- tz.transition 1975, 10, :o4, 181695600
- tz.transition 1976, 3, :o5, 196812000
- tz.transition 1976, 9, :o4, 212540400
- tz.transition 1977, 4, :o5, 228866400
- tz.transition 1977, 9, :o4, 243990000
- tz.transition 1978, 4, :o5, 260402400
- tz.transition 1978, 9, :o4, 276044400
- tz.transition 1979, 4, :o5, 291776400
- tz.transition 1979, 9, :o4, 307501200
- tz.transition 1980, 4, :o5, 323830800
- tz.transition 1980, 9, :o4, 338950800
- tz.transition 1981, 3, :o5, 354675600
- tz.transition 1981, 9, :o4, 370400400
- tz.transition 1982, 3, :o5, 386125200
- tz.transition 1982, 9, :o4, 401850000
- tz.transition 1983, 3, :o5, 417574800
- tz.transition 1983, 9, :o4, 433299600
- tz.transition 1984, 3, :o5, 449024400
- tz.transition 1984, 9, :o4, 465354000
- tz.transition 1985, 3, :o5, 481078800
- tz.transition 1985, 9, :o4, 496803600
- tz.transition 1986, 3, :o5, 512528400
- tz.transition 1986, 9, :o4, 528253200
- tz.transition 1987, 3, :o5, 543978000
- tz.transition 1987, 9, :o4, 559702800
- tz.transition 1988, 3, :o5, 575427600
- tz.transition 1988, 9, :o4, 591152400
- tz.transition 1989, 3, :o5, 606877200
- tz.transition 1989, 9, :o4, 622602000
- tz.transition 1990, 3, :o5, 638326800
- tz.transition 1990, 9, :o4, 654656400
- tz.transition 1991, 3, :o5, 670381200
- tz.transition 1991, 9, :o4, 686106000
- tz.transition 1992, 3, :o5, 701830800
- tz.transition 1992, 9, :o4, 717555600
- tz.transition 1993, 3, :o5, 733280400
- tz.transition 1993, 9, :o4, 749005200
- tz.transition 1994, 3, :o5, 764730000
- tz.transition 1994, 9, :o4, 780454800
- tz.transition 1995, 3, :o5, 796179600
- tz.transition 1995, 9, :o4, 811904400
- tz.transition 1996, 3, :o5, 828234000
- tz.transition 1996, 10, :o4, 846378000
- tz.transition 1997, 3, :o5, 859683600
- tz.transition 1997, 10, :o4, 877827600
- tz.transition 1998, 3, :o5, 891133200
- tz.transition 1998, 10, :o4, 909277200
- tz.transition 1999, 3, :o5, 922582800
- tz.transition 1999, 10, :o4, 941331600
- tz.transition 2000, 3, :o5, 954032400
- tz.transition 2000, 10, :o4, 972781200
- tz.transition 2001, 3, :o5, 985482000
- tz.transition 2001, 10, :o4, 1004230800
- tz.transition 2002, 3, :o5, 1017536400
- tz.transition 2002, 10, :o4, 1035680400
- tz.transition 2003, 3, :o5, 1048986000
- tz.transition 2003, 10, :o4, 1067130000
- tz.transition 2004, 3, :o5, 1080435600
- tz.transition 2004, 10, :o4, 1099184400
- tz.transition 2005, 3, :o5, 1111885200
- tz.transition 2005, 10, :o4, 1130634000
- tz.transition 2006, 3, :o5, 1143334800
- tz.transition 2006, 10, :o4, 1162083600
- tz.transition 2007, 3, :o5, 1174784400
- tz.transition 2007, 10, :o4, 1193533200
- tz.transition 2008, 3, :o5, 1206838800
- tz.transition 2008, 10, :o4, 1224982800
- tz.transition 2009, 3, :o5, 1238288400
- tz.transition 2009, 10, :o4, 1256432400
- tz.transition 2010, 3, :o5, 1269738000
- tz.transition 2010, 10, :o4, 1288486800
- tz.transition 2011, 3, :o5, 1301187600
- tz.transition 2011, 10, :o4, 1319936400
- tz.transition 2012, 3, :o5, 1332637200
- tz.transition 2012, 10, :o4, 1351386000
- tz.transition 2013, 3, :o5, 1364691600
- tz.transition 2013, 10, :o4, 1382835600
- tz.transition 2014, 3, :o5, 1396141200
- tz.transition 2014, 10, :o4, 1414285200
- tz.transition 2015, 3, :o5, 1427590800
- tz.transition 2015, 10, :o4, 1445734800
- tz.transition 2016, 3, :o5, 1459040400
- tz.transition 2016, 10, :o4, 1477789200
- tz.transition 2017, 3, :o5, 1490490000
- tz.transition 2017, 10, :o4, 1509238800
- tz.transition 2018, 3, :o5, 1521939600
- tz.transition 2018, 10, :o4, 1540688400
- tz.transition 2019, 3, :o5, 1553994000
- tz.transition 2019, 10, :o4, 1572138000
- tz.transition 2020, 3, :o5, 1585443600
- tz.transition 2020, 10, :o4, 1603587600
- tz.transition 2021, 3, :o5, 1616893200
- tz.transition 2021, 10, :o4, 1635642000
- tz.transition 2022, 3, :o5, 1648342800
- tz.transition 2022, 10, :o4, 1667091600
- tz.transition 2023, 3, :o5, 1679792400
- tz.transition 2023, 10, :o4, 1698541200
- tz.transition 2024, 3, :o5, 1711846800
- tz.transition 2024, 10, :o4, 1729990800
- tz.transition 2025, 3, :o5, 1743296400
- tz.transition 2025, 10, :o4, 1761440400
- tz.transition 2026, 3, :o5, 1774746000
- tz.transition 2026, 10, :o4, 1792890000
- tz.transition 2027, 3, :o5, 1806195600
- tz.transition 2027, 10, :o4, 1824944400
- tz.transition 2028, 3, :o5, 1837645200
- tz.transition 2028, 10, :o4, 1856394000
- tz.transition 2029, 3, :o5, 1869094800
- tz.transition 2029, 10, :o4, 1887843600
- tz.transition 2030, 3, :o5, 1901149200
- tz.transition 2030, 10, :o4, 1919293200
- tz.transition 2031, 3, :o5, 1932598800
- tz.transition 2031, 10, :o4, 1950742800
- tz.transition 2032, 3, :o5, 1964048400
- tz.transition 2032, 10, :o4, 1982797200
- tz.transition 2033, 3, :o5, 1995498000
- tz.transition 2033, 10, :o4, 2014246800
- tz.transition 2034, 3, :o5, 2026947600
- tz.transition 2034, 10, :o4, 2045696400
- tz.transition 2035, 3, :o5, 2058397200
- tz.transition 2035, 10, :o4, 2077146000
- tz.transition 2036, 3, :o5, 2090451600
- tz.transition 2036, 10, :o4, 2108595600
- tz.transition 2037, 3, :o5, 2121901200
- tz.transition 2037, 10, :o4, 2140045200
- tz.transition 2038, 3, :o5, 59172253, 24
- tz.transition 2038, 10, :o4, 59177461, 24
- tz.transition 2039, 3, :o5, 59180989, 24
- tz.transition 2039, 10, :o4, 59186197, 24
- tz.transition 2040, 3, :o5, 59189725, 24
- tz.transition 2040, 10, :o4, 59194933, 24
- tz.transition 2041, 3, :o5, 59198629, 24
- tz.transition 2041, 10, :o4, 59203669, 24
- tz.transition 2042, 3, :o5, 59207365, 24
- tz.transition 2042, 10, :o4, 59212405, 24
- tz.transition 2043, 3, :o5, 59216101, 24
- tz.transition 2043, 10, :o4, 59221141, 24
- tz.transition 2044, 3, :o5, 59224837, 24
- tz.transition 2044, 10, :o4, 59230045, 24
- tz.transition 2045, 3, :o5, 59233573, 24
- tz.transition 2045, 10, :o4, 59238781, 24
- tz.transition 2046, 3, :o5, 59242309, 24
- tz.transition 2046, 10, :o4, 59247517, 24
- tz.transition 2047, 3, :o5, 59251213, 24
- tz.transition 2047, 10, :o4, 59256253, 24
- tz.transition 2048, 3, :o5, 59259949, 24
- tz.transition 2048, 10, :o4, 59264989, 24
- tz.transition 2049, 3, :o5, 59268685, 24
- tz.transition 2049, 10, :o4, 59273893, 24
- tz.transition 2050, 3, :o5, 59277421, 24
- tz.transition 2050, 10, :o4, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Minsk.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Minsk.rb
deleted file mode 100644
index fa15816cc8..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Minsk.rb
+++ /dev/null
@@ -1,170 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Minsk
- include TimezoneDefinition
-
- timezone 'Europe/Minsk' do |tz|
- tz.offset :o0, 6616, 0, :LMT
- tz.offset :o1, 6600, 0, :MMT
- tz.offset :o2, 7200, 0, :EET
- tz.offset :o3, 10800, 0, :MSK
- tz.offset :o4, 3600, 3600, :CEST
- tz.offset :o5, 3600, 0, :CET
- tz.offset :o6, 10800, 3600, :MSD
- tz.offset :o7, 7200, 3600, :EEST
-
- tz.transition 1879, 12, :o1, 26003326573, 10800
- tz.transition 1924, 5, :o2, 349042669, 144
- tz.transition 1930, 6, :o3, 29113781, 12
- tz.transition 1941, 6, :o4, 19441387, 8
- tz.transition 1942, 11, :o5, 58335973, 24
- tz.transition 1943, 3, :o4, 58339501, 24
- tz.transition 1943, 10, :o5, 58344037, 24
- tz.transition 1944, 4, :o4, 58348405, 24
- tz.transition 1944, 7, :o3, 29175293, 12
- tz.transition 1981, 3, :o6, 354920400
- tz.transition 1981, 9, :o3, 370728000
- tz.transition 1982, 3, :o6, 386456400
- tz.transition 1982, 9, :o3, 402264000
- tz.transition 1983, 3, :o6, 417992400
- tz.transition 1983, 9, :o3, 433800000
- tz.transition 1984, 3, :o6, 449614800
- tz.transition 1984, 9, :o3, 465346800
- tz.transition 1985, 3, :o6, 481071600
- tz.transition 1985, 9, :o3, 496796400
- tz.transition 1986, 3, :o6, 512521200
- tz.transition 1986, 9, :o3, 528246000
- tz.transition 1987, 3, :o6, 543970800
- tz.transition 1987, 9, :o3, 559695600
- tz.transition 1988, 3, :o6, 575420400
- tz.transition 1988, 9, :o3, 591145200
- tz.transition 1989, 3, :o6, 606870000
- tz.transition 1989, 9, :o3, 622594800
- tz.transition 1991, 3, :o7, 670374000
- tz.transition 1991, 9, :o2, 686102400
- tz.transition 1992, 3, :o7, 701820000
- tz.transition 1992, 9, :o2, 717544800
- tz.transition 1993, 3, :o7, 733276800
- tz.transition 1993, 9, :o2, 749001600
- tz.transition 1994, 3, :o7, 764726400
- tz.transition 1994, 9, :o2, 780451200
- tz.transition 1995, 3, :o7, 796176000
- tz.transition 1995, 9, :o2, 811900800
- tz.transition 1996, 3, :o7, 828230400
- tz.transition 1996, 10, :o2, 846374400
- tz.transition 1997, 3, :o7, 859680000
- tz.transition 1997, 10, :o2, 877824000
- tz.transition 1998, 3, :o7, 891129600
- tz.transition 1998, 10, :o2, 909273600
- tz.transition 1999, 3, :o7, 922579200
- tz.transition 1999, 10, :o2, 941328000
- tz.transition 2000, 3, :o7, 954028800
- tz.transition 2000, 10, :o2, 972777600
- tz.transition 2001, 3, :o7, 985478400
- tz.transition 2001, 10, :o2, 1004227200
- tz.transition 2002, 3, :o7, 1017532800
- tz.transition 2002, 10, :o2, 1035676800
- tz.transition 2003, 3, :o7, 1048982400
- tz.transition 2003, 10, :o2, 1067126400
- tz.transition 2004, 3, :o7, 1080432000
- tz.transition 2004, 10, :o2, 1099180800
- tz.transition 2005, 3, :o7, 1111881600
- tz.transition 2005, 10, :o2, 1130630400
- tz.transition 2006, 3, :o7, 1143331200
- tz.transition 2006, 10, :o2, 1162080000
- tz.transition 2007, 3, :o7, 1174780800
- tz.transition 2007, 10, :o2, 1193529600
- tz.transition 2008, 3, :o7, 1206835200
- tz.transition 2008, 10, :o2, 1224979200
- tz.transition 2009, 3, :o7, 1238284800
- tz.transition 2009, 10, :o2, 1256428800
- tz.transition 2010, 3, :o7, 1269734400
- tz.transition 2010, 10, :o2, 1288483200
- tz.transition 2011, 3, :o7, 1301184000
- tz.transition 2011, 10, :o2, 1319932800
- tz.transition 2012, 3, :o7, 1332633600
- tz.transition 2012, 10, :o2, 1351382400
- tz.transition 2013, 3, :o7, 1364688000
- tz.transition 2013, 10, :o2, 1382832000
- tz.transition 2014, 3, :o7, 1396137600
- tz.transition 2014, 10, :o2, 1414281600
- tz.transition 2015, 3, :o7, 1427587200
- tz.transition 2015, 10, :o2, 1445731200
- tz.transition 2016, 3, :o7, 1459036800
- tz.transition 2016, 10, :o2, 1477785600
- tz.transition 2017, 3, :o7, 1490486400
- tz.transition 2017, 10, :o2, 1509235200
- tz.transition 2018, 3, :o7, 1521936000
- tz.transition 2018, 10, :o2, 1540684800
- tz.transition 2019, 3, :o7, 1553990400
- tz.transition 2019, 10, :o2, 1572134400
- tz.transition 2020, 3, :o7, 1585440000
- tz.transition 2020, 10, :o2, 1603584000
- tz.transition 2021, 3, :o7, 1616889600
- tz.transition 2021, 10, :o2, 1635638400
- tz.transition 2022, 3, :o7, 1648339200
- tz.transition 2022, 10, :o2, 1667088000
- tz.transition 2023, 3, :o7, 1679788800
- tz.transition 2023, 10, :o2, 1698537600
- tz.transition 2024, 3, :o7, 1711843200
- tz.transition 2024, 10, :o2, 1729987200
- tz.transition 2025, 3, :o7, 1743292800
- tz.transition 2025, 10, :o2, 1761436800
- tz.transition 2026, 3, :o7, 1774742400
- tz.transition 2026, 10, :o2, 1792886400
- tz.transition 2027, 3, :o7, 1806192000
- tz.transition 2027, 10, :o2, 1824940800
- tz.transition 2028, 3, :o7, 1837641600
- tz.transition 2028, 10, :o2, 1856390400
- tz.transition 2029, 3, :o7, 1869091200
- tz.transition 2029, 10, :o2, 1887840000
- tz.transition 2030, 3, :o7, 1901145600
- tz.transition 2030, 10, :o2, 1919289600
- tz.transition 2031, 3, :o7, 1932595200
- tz.transition 2031, 10, :o2, 1950739200
- tz.transition 2032, 3, :o7, 1964044800
- tz.transition 2032, 10, :o2, 1982793600
- tz.transition 2033, 3, :o7, 1995494400
- tz.transition 2033, 10, :o2, 2014243200
- tz.transition 2034, 3, :o7, 2026944000
- tz.transition 2034, 10, :o2, 2045692800
- tz.transition 2035, 3, :o7, 2058393600
- tz.transition 2035, 10, :o2, 2077142400
- tz.transition 2036, 3, :o7, 2090448000
- tz.transition 2036, 10, :o2, 2108592000
- tz.transition 2037, 3, :o7, 2121897600
- tz.transition 2037, 10, :o2, 2140041600
- tz.transition 2038, 3, :o7, 4931021, 2
- tz.transition 2038, 10, :o2, 4931455, 2
- tz.transition 2039, 3, :o7, 4931749, 2
- tz.transition 2039, 10, :o2, 4932183, 2
- tz.transition 2040, 3, :o7, 4932477, 2
- tz.transition 2040, 10, :o2, 4932911, 2
- tz.transition 2041, 3, :o7, 4933219, 2
- tz.transition 2041, 10, :o2, 4933639, 2
- tz.transition 2042, 3, :o7, 4933947, 2
- tz.transition 2042, 10, :o2, 4934367, 2
- tz.transition 2043, 3, :o7, 4934675, 2
- tz.transition 2043, 10, :o2, 4935095, 2
- tz.transition 2044, 3, :o7, 4935403, 2
- tz.transition 2044, 10, :o2, 4935837, 2
- tz.transition 2045, 3, :o7, 4936131, 2
- tz.transition 2045, 10, :o2, 4936565, 2
- tz.transition 2046, 3, :o7, 4936859, 2
- tz.transition 2046, 10, :o2, 4937293, 2
- tz.transition 2047, 3, :o7, 4937601, 2
- tz.transition 2047, 10, :o2, 4938021, 2
- tz.transition 2048, 3, :o7, 4938329, 2
- tz.transition 2048, 10, :o2, 4938749, 2
- tz.transition 2049, 3, :o7, 4939057, 2
- tz.transition 2049, 10, :o2, 4939491, 2
- tz.transition 2050, 3, :o7, 4939785, 2
- tz.transition 2050, 10, :o2, 4940219, 2
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Moscow.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Moscow.rb
deleted file mode 100644
index ef269b675b..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Moscow.rb
+++ /dev/null
@@ -1,181 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Moscow
- include TimezoneDefinition
-
- timezone 'Europe/Moscow' do |tz|
- tz.offset :o0, 9020, 0, :LMT
- tz.offset :o1, 9000, 0, :MMT
- tz.offset :o2, 9048, 0, :MMT
- tz.offset :o3, 9048, 3600, :MST
- tz.offset :o4, 9048, 7200, :MDST
- tz.offset :o5, 10800, 3600, :MSD
- tz.offset :o6, 10800, 0, :MSK
- tz.offset :o7, 10800, 7200, :MSD
- tz.offset :o8, 7200, 0, :EET
- tz.offset :o9, 7200, 3600, :EEST
-
- tz.transition 1879, 12, :o1, 10401330509, 4320
- tz.transition 1916, 7, :o2, 116210275, 48
- tz.transition 1917, 7, :o3, 8717080873, 3600
- tz.transition 1917, 12, :o2, 8717725273, 3600
- tz.transition 1918, 5, :o4, 8718283123, 3600
- tz.transition 1918, 9, :o3, 8718668473, 3600
- tz.transition 1919, 5, :o4, 8719597123, 3600
- tz.transition 1919, 6, :o5, 8719705423, 3600
- tz.transition 1919, 8, :o6, 7266559, 3
- tz.transition 1921, 2, :o5, 7268206, 3
- tz.transition 1921, 3, :o7, 58146463, 24
- tz.transition 1921, 8, :o5, 58150399, 24
- tz.transition 1921, 9, :o6, 7268890, 3
- tz.transition 1922, 9, :o8, 19386627, 8
- tz.transition 1930, 6, :o6, 29113781, 12
- tz.transition 1981, 3, :o5, 354920400
- tz.transition 1981, 9, :o6, 370728000
- tz.transition 1982, 3, :o5, 386456400
- tz.transition 1982, 9, :o6, 402264000
- tz.transition 1983, 3, :o5, 417992400
- tz.transition 1983, 9, :o6, 433800000
- tz.transition 1984, 3, :o5, 449614800
- tz.transition 1984, 9, :o6, 465346800
- tz.transition 1985, 3, :o5, 481071600
- tz.transition 1985, 9, :o6, 496796400
- tz.transition 1986, 3, :o5, 512521200
- tz.transition 1986, 9, :o6, 528246000
- tz.transition 1987, 3, :o5, 543970800
- tz.transition 1987, 9, :o6, 559695600
- tz.transition 1988, 3, :o5, 575420400
- tz.transition 1988, 9, :o6, 591145200
- tz.transition 1989, 3, :o5, 606870000
- tz.transition 1989, 9, :o6, 622594800
- tz.transition 1990, 3, :o5, 638319600
- tz.transition 1990, 9, :o6, 654649200
- tz.transition 1991, 3, :o9, 670374000
- tz.transition 1991, 9, :o8, 686102400
- tz.transition 1992, 1, :o6, 695779200
- tz.transition 1992, 3, :o5, 701812800
- tz.transition 1992, 9, :o6, 717534000
- tz.transition 1993, 3, :o5, 733273200
- tz.transition 1993, 9, :o6, 748998000
- tz.transition 1994, 3, :o5, 764722800
- tz.transition 1994, 9, :o6, 780447600
- tz.transition 1995, 3, :o5, 796172400
- tz.transition 1995, 9, :o6, 811897200
- tz.transition 1996, 3, :o5, 828226800
- tz.transition 1996, 10, :o6, 846370800
- tz.transition 1997, 3, :o5, 859676400
- tz.transition 1997, 10, :o6, 877820400
- tz.transition 1998, 3, :o5, 891126000
- tz.transition 1998, 10, :o6, 909270000
- tz.transition 1999, 3, :o5, 922575600
- tz.transition 1999, 10, :o6, 941324400
- tz.transition 2000, 3, :o5, 954025200
- tz.transition 2000, 10, :o6, 972774000
- tz.transition 2001, 3, :o5, 985474800
- tz.transition 2001, 10, :o6, 1004223600
- tz.transition 2002, 3, :o5, 1017529200
- tz.transition 2002, 10, :o6, 1035673200
- tz.transition 2003, 3, :o5, 1048978800
- tz.transition 2003, 10, :o6, 1067122800
- tz.transition 2004, 3, :o5, 1080428400
- tz.transition 2004, 10, :o6, 1099177200
- tz.transition 2005, 3, :o5, 1111878000
- tz.transition 2005, 10, :o6, 1130626800
- tz.transition 2006, 3, :o5, 1143327600
- tz.transition 2006, 10, :o6, 1162076400
- tz.transition 2007, 3, :o5, 1174777200
- tz.transition 2007, 10, :o6, 1193526000
- tz.transition 2008, 3, :o5, 1206831600
- tz.transition 2008, 10, :o6, 1224975600
- tz.transition 2009, 3, :o5, 1238281200
- tz.transition 2009, 10, :o6, 1256425200
- tz.transition 2010, 3, :o5, 1269730800
- tz.transition 2010, 10, :o6, 1288479600
- tz.transition 2011, 3, :o5, 1301180400
- tz.transition 2011, 10, :o6, 1319929200
- tz.transition 2012, 3, :o5, 1332630000
- tz.transition 2012, 10, :o6, 1351378800
- tz.transition 2013, 3, :o5, 1364684400
- tz.transition 2013, 10, :o6, 1382828400
- tz.transition 2014, 3, :o5, 1396134000
- tz.transition 2014, 10, :o6, 1414278000
- tz.transition 2015, 3, :o5, 1427583600
- tz.transition 2015, 10, :o6, 1445727600
- tz.transition 2016, 3, :o5, 1459033200
- tz.transition 2016, 10, :o6, 1477782000
- tz.transition 2017, 3, :o5, 1490482800
- tz.transition 2017, 10, :o6, 1509231600
- tz.transition 2018, 3, :o5, 1521932400
- tz.transition 2018, 10, :o6, 1540681200
- tz.transition 2019, 3, :o5, 1553986800
- tz.transition 2019, 10, :o6, 1572130800
- tz.transition 2020, 3, :o5, 1585436400
- tz.transition 2020, 10, :o6, 1603580400
- tz.transition 2021, 3, :o5, 1616886000
- tz.transition 2021, 10, :o6, 1635634800
- tz.transition 2022, 3, :o5, 1648335600
- tz.transition 2022, 10, :o6, 1667084400
- tz.transition 2023, 3, :o5, 1679785200
- tz.transition 2023, 10, :o6, 1698534000
- tz.transition 2024, 3, :o5, 1711839600
- tz.transition 2024, 10, :o6, 1729983600
- tz.transition 2025, 3, :o5, 1743289200
- tz.transition 2025, 10, :o6, 1761433200
- tz.transition 2026, 3, :o5, 1774738800
- tz.transition 2026, 10, :o6, 1792882800
- tz.transition 2027, 3, :o5, 1806188400
- tz.transition 2027, 10, :o6, 1824937200
- tz.transition 2028, 3, :o5, 1837638000
- tz.transition 2028, 10, :o6, 1856386800
- tz.transition 2029, 3, :o5, 1869087600
- tz.transition 2029, 10, :o6, 1887836400
- tz.transition 2030, 3, :o5, 1901142000
- tz.transition 2030, 10, :o6, 1919286000
- tz.transition 2031, 3, :o5, 1932591600
- tz.transition 2031, 10, :o6, 1950735600
- tz.transition 2032, 3, :o5, 1964041200
- tz.transition 2032, 10, :o6, 1982790000
- tz.transition 2033, 3, :o5, 1995490800
- tz.transition 2033, 10, :o6, 2014239600
- tz.transition 2034, 3, :o5, 2026940400
- tz.transition 2034, 10, :o6, 2045689200
- tz.transition 2035, 3, :o5, 2058390000
- tz.transition 2035, 10, :o6, 2077138800
- tz.transition 2036, 3, :o5, 2090444400
- tz.transition 2036, 10, :o6, 2108588400
- tz.transition 2037, 3, :o5, 2121894000
- tz.transition 2037, 10, :o6, 2140038000
- tz.transition 2038, 3, :o5, 59172251, 24
- tz.transition 2038, 10, :o6, 59177459, 24
- tz.transition 2039, 3, :o5, 59180987, 24
- tz.transition 2039, 10, :o6, 59186195, 24
- tz.transition 2040, 3, :o5, 59189723, 24
- tz.transition 2040, 10, :o6, 59194931, 24
- tz.transition 2041, 3, :o5, 59198627, 24
- tz.transition 2041, 10, :o6, 59203667, 24
- tz.transition 2042, 3, :o5, 59207363, 24
- tz.transition 2042, 10, :o6, 59212403, 24
- tz.transition 2043, 3, :o5, 59216099, 24
- tz.transition 2043, 10, :o6, 59221139, 24
- tz.transition 2044, 3, :o5, 59224835, 24
- tz.transition 2044, 10, :o6, 59230043, 24
- tz.transition 2045, 3, :o5, 59233571, 24
- tz.transition 2045, 10, :o6, 59238779, 24
- tz.transition 2046, 3, :o5, 59242307, 24
- tz.transition 2046, 10, :o6, 59247515, 24
- tz.transition 2047, 3, :o5, 59251211, 24
- tz.transition 2047, 10, :o6, 59256251, 24
- tz.transition 2048, 3, :o5, 59259947, 24
- tz.transition 2048, 10, :o6, 59264987, 24
- tz.transition 2049, 3, :o5, 59268683, 24
- tz.transition 2049, 10, :o6, 59273891, 24
- tz.transition 2050, 3, :o5, 59277419, 24
- tz.transition 2050, 10, :o6, 59282627, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Paris.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Paris.rb
deleted file mode 100644
index e3236c0ba1..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Paris.rb
+++ /dev/null
@@ -1,232 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Paris
- include TimezoneDefinition
-
- timezone 'Europe/Paris' do |tz|
- tz.offset :o0, 561, 0, :LMT
- tz.offset :o1, 561, 0, :PMT
- tz.offset :o2, 0, 0, :WET
- tz.offset :o3, 0, 3600, :WEST
- tz.offset :o4, 3600, 3600, :CEST
- tz.offset :o5, 3600, 0, :CET
- tz.offset :o6, 0, 7200, :WEMT
-
- tz.transition 1891, 3, :o1, 69460027033, 28800
- tz.transition 1911, 3, :o2, 69670267033, 28800
- tz.transition 1916, 6, :o3, 58104707, 24
- tz.transition 1916, 10, :o2, 58107323, 24
- tz.transition 1917, 3, :o3, 58111499, 24
- tz.transition 1917, 10, :o2, 58116227, 24
- tz.transition 1918, 3, :o3, 58119899, 24
- tz.transition 1918, 10, :o2, 58124963, 24
- tz.transition 1919, 3, :o3, 58128467, 24
- tz.transition 1919, 10, :o2, 58133699, 24
- tz.transition 1920, 2, :o3, 58136867, 24
- tz.transition 1920, 10, :o2, 58142915, 24
- tz.transition 1921, 3, :o3, 58146323, 24
- tz.transition 1921, 10, :o2, 58151723, 24
- tz.transition 1922, 3, :o3, 58155347, 24
- tz.transition 1922, 10, :o2, 58160051, 24
- tz.transition 1923, 5, :o3, 58165595, 24
- tz.transition 1923, 10, :o2, 58168787, 24
- tz.transition 1924, 3, :o3, 58172987, 24
- tz.transition 1924, 10, :o2, 58177523, 24
- tz.transition 1925, 4, :o3, 58181891, 24
- tz.transition 1925, 10, :o2, 58186259, 24
- tz.transition 1926, 4, :o3, 58190963, 24
- tz.transition 1926, 10, :o2, 58194995, 24
- tz.transition 1927, 4, :o3, 58199531, 24
- tz.transition 1927, 10, :o2, 58203731, 24
- tz.transition 1928, 4, :o3, 58208435, 24
- tz.transition 1928, 10, :o2, 58212635, 24
- tz.transition 1929, 4, :o3, 58217339, 24
- tz.transition 1929, 10, :o2, 58221371, 24
- tz.transition 1930, 4, :o3, 58225907, 24
- tz.transition 1930, 10, :o2, 58230107, 24
- tz.transition 1931, 4, :o3, 58234811, 24
- tz.transition 1931, 10, :o2, 58238843, 24
- tz.transition 1932, 4, :o3, 58243211, 24
- tz.transition 1932, 10, :o2, 58247579, 24
- tz.transition 1933, 3, :o3, 58251779, 24
- tz.transition 1933, 10, :o2, 58256483, 24
- tz.transition 1934, 4, :o3, 58260851, 24
- tz.transition 1934, 10, :o2, 58265219, 24
- tz.transition 1935, 3, :o3, 58269419, 24
- tz.transition 1935, 10, :o2, 58273955, 24
- tz.transition 1936, 4, :o3, 58278659, 24
- tz.transition 1936, 10, :o2, 58282691, 24
- tz.transition 1937, 4, :o3, 58287059, 24
- tz.transition 1937, 10, :o2, 58291427, 24
- tz.transition 1938, 3, :o3, 58295627, 24
- tz.transition 1938, 10, :o2, 58300163, 24
- tz.transition 1939, 4, :o3, 58304867, 24
- tz.transition 1939, 11, :o2, 58310075, 24
- tz.transition 1940, 2, :o3, 29156215, 12
- tz.transition 1940, 6, :o4, 29157545, 12
- tz.transition 1942, 11, :o5, 58335973, 24
- tz.transition 1943, 3, :o4, 58339501, 24
- tz.transition 1943, 10, :o5, 58344037, 24
- tz.transition 1944, 4, :o4, 58348405, 24
- tz.transition 1944, 8, :o6, 29175929, 12
- tz.transition 1944, 10, :o3, 58352915, 24
- tz.transition 1945, 4, :o6, 58357141, 24
- tz.transition 1945, 9, :o5, 58361149, 24
- tz.transition 1976, 3, :o4, 196819200
- tz.transition 1976, 9, :o5, 212540400
- tz.transition 1977, 4, :o4, 228877200
- tz.transition 1977, 9, :o5, 243997200
- tz.transition 1978, 4, :o4, 260326800
- tz.transition 1978, 10, :o5, 276051600
- tz.transition 1979, 4, :o4, 291776400
- tz.transition 1979, 9, :o5, 307501200
- tz.transition 1980, 4, :o4, 323830800
- tz.transition 1980, 9, :o5, 338950800
- tz.transition 1981, 3, :o4, 354675600
- tz.transition 1981, 9, :o5, 370400400
- tz.transition 1982, 3, :o4, 386125200
- tz.transition 1982, 9, :o5, 401850000
- tz.transition 1983, 3, :o4, 417574800
- tz.transition 1983, 9, :o5, 433299600
- tz.transition 1984, 3, :o4, 449024400
- tz.transition 1984, 9, :o5, 465354000
- tz.transition 1985, 3, :o4, 481078800
- tz.transition 1985, 9, :o5, 496803600
- tz.transition 1986, 3, :o4, 512528400
- tz.transition 1986, 9, :o5, 528253200
- tz.transition 1987, 3, :o4, 543978000
- tz.transition 1987, 9, :o5, 559702800
- tz.transition 1988, 3, :o4, 575427600
- tz.transition 1988, 9, :o5, 591152400
- tz.transition 1989, 3, :o4, 606877200
- tz.transition 1989, 9, :o5, 622602000
- tz.transition 1990, 3, :o4, 638326800
- tz.transition 1990, 9, :o5, 654656400
- tz.transition 1991, 3, :o4, 670381200
- tz.transition 1991, 9, :o5, 686106000
- tz.transition 1992, 3, :o4, 701830800
- tz.transition 1992, 9, :o5, 717555600
- tz.transition 1993, 3, :o4, 733280400
- tz.transition 1993, 9, :o5, 749005200
- tz.transition 1994, 3, :o4, 764730000
- tz.transition 1994, 9, :o5, 780454800
- tz.transition 1995, 3, :o4, 796179600
- tz.transition 1995, 9, :o5, 811904400
- tz.transition 1996, 3, :o4, 828234000
- tz.transition 1996, 10, :o5, 846378000
- tz.transition 1997, 3, :o4, 859683600
- tz.transition 1997, 10, :o5, 877827600
- tz.transition 1998, 3, :o4, 891133200
- tz.transition 1998, 10, :o5, 909277200
- tz.transition 1999, 3, :o4, 922582800
- tz.transition 1999, 10, :o5, 941331600
- tz.transition 2000, 3, :o4, 954032400
- tz.transition 2000, 10, :o5, 972781200
- tz.transition 2001, 3, :o4, 985482000
- tz.transition 2001, 10, :o5, 1004230800
- tz.transition 2002, 3, :o4, 1017536400
- tz.transition 2002, 10, :o5, 1035680400
- tz.transition 2003, 3, :o4, 1048986000
- tz.transition 2003, 10, :o5, 1067130000
- tz.transition 2004, 3, :o4, 1080435600
- tz.transition 2004, 10, :o5, 1099184400
- tz.transition 2005, 3, :o4, 1111885200
- tz.transition 2005, 10, :o5, 1130634000
- tz.transition 2006, 3, :o4, 1143334800
- tz.transition 2006, 10, :o5, 1162083600
- tz.transition 2007, 3, :o4, 1174784400
- tz.transition 2007, 10, :o5, 1193533200
- tz.transition 2008, 3, :o4, 1206838800
- tz.transition 2008, 10, :o5, 1224982800
- tz.transition 2009, 3, :o4, 1238288400
- tz.transition 2009, 10, :o5, 1256432400
- tz.transition 2010, 3, :o4, 1269738000
- tz.transition 2010, 10, :o5, 1288486800
- tz.transition 2011, 3, :o4, 1301187600
- tz.transition 2011, 10, :o5, 1319936400
- tz.transition 2012, 3, :o4, 1332637200
- tz.transition 2012, 10, :o5, 1351386000
- tz.transition 2013, 3, :o4, 1364691600
- tz.transition 2013, 10, :o5, 1382835600
- tz.transition 2014, 3, :o4, 1396141200
- tz.transition 2014, 10, :o5, 1414285200
- tz.transition 2015, 3, :o4, 1427590800
- tz.transition 2015, 10, :o5, 1445734800
- tz.transition 2016, 3, :o4, 1459040400
- tz.transition 2016, 10, :o5, 1477789200
- tz.transition 2017, 3, :o4, 1490490000
- tz.transition 2017, 10, :o5, 1509238800
- tz.transition 2018, 3, :o4, 1521939600
- tz.transition 2018, 10, :o5, 1540688400
- tz.transition 2019, 3, :o4, 1553994000
- tz.transition 2019, 10, :o5, 1572138000
- tz.transition 2020, 3, :o4, 1585443600
- tz.transition 2020, 10, :o5, 1603587600
- tz.transition 2021, 3, :o4, 1616893200
- tz.transition 2021, 10, :o5, 1635642000
- tz.transition 2022, 3, :o4, 1648342800
- tz.transition 2022, 10, :o5, 1667091600
- tz.transition 2023, 3, :o4, 1679792400
- tz.transition 2023, 10, :o5, 1698541200
- tz.transition 2024, 3, :o4, 1711846800
- tz.transition 2024, 10, :o5, 1729990800
- tz.transition 2025, 3, :o4, 1743296400
- tz.transition 2025, 10, :o5, 1761440400
- tz.transition 2026, 3, :o4, 1774746000
- tz.transition 2026, 10, :o5, 1792890000
- tz.transition 2027, 3, :o4, 1806195600
- tz.transition 2027, 10, :o5, 1824944400
- tz.transition 2028, 3, :o4, 1837645200
- tz.transition 2028, 10, :o5, 1856394000
- tz.transition 2029, 3, :o4, 1869094800
- tz.transition 2029, 10, :o5, 1887843600
- tz.transition 2030, 3, :o4, 1901149200
- tz.transition 2030, 10, :o5, 1919293200
- tz.transition 2031, 3, :o4, 1932598800
- tz.transition 2031, 10, :o5, 1950742800
- tz.transition 2032, 3, :o4, 1964048400
- tz.transition 2032, 10, :o5, 1982797200
- tz.transition 2033, 3, :o4, 1995498000
- tz.transition 2033, 10, :o5, 2014246800
- tz.transition 2034, 3, :o4, 2026947600
- tz.transition 2034, 10, :o5, 2045696400
- tz.transition 2035, 3, :o4, 2058397200
- tz.transition 2035, 10, :o5, 2077146000
- tz.transition 2036, 3, :o4, 2090451600
- tz.transition 2036, 10, :o5, 2108595600
- tz.transition 2037, 3, :o4, 2121901200
- tz.transition 2037, 10, :o5, 2140045200
- tz.transition 2038, 3, :o4, 59172253, 24
- tz.transition 2038, 10, :o5, 59177461, 24
- tz.transition 2039, 3, :o4, 59180989, 24
- tz.transition 2039, 10, :o5, 59186197, 24
- tz.transition 2040, 3, :o4, 59189725, 24
- tz.transition 2040, 10, :o5, 59194933, 24
- tz.transition 2041, 3, :o4, 59198629, 24
- tz.transition 2041, 10, :o5, 59203669, 24
- tz.transition 2042, 3, :o4, 59207365, 24
- tz.transition 2042, 10, :o5, 59212405, 24
- tz.transition 2043, 3, :o4, 59216101, 24
- tz.transition 2043, 10, :o5, 59221141, 24
- tz.transition 2044, 3, :o4, 59224837, 24
- tz.transition 2044, 10, :o5, 59230045, 24
- tz.transition 2045, 3, :o4, 59233573, 24
- tz.transition 2045, 10, :o5, 59238781, 24
- tz.transition 2046, 3, :o4, 59242309, 24
- tz.transition 2046, 10, :o5, 59247517, 24
- tz.transition 2047, 3, :o4, 59251213, 24
- tz.transition 2047, 10, :o5, 59256253, 24
- tz.transition 2048, 3, :o4, 59259949, 24
- tz.transition 2048, 10, :o5, 59264989, 24
- tz.transition 2049, 3, :o4, 59268685, 24
- tz.transition 2049, 10, :o5, 59273893, 24
- tz.transition 2050, 3, :o4, 59277421, 24
- tz.transition 2050, 10, :o5, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Prague.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Prague.rb
deleted file mode 100644
index bcabee96c1..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Prague.rb
+++ /dev/null
@@ -1,187 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Prague
- include TimezoneDefinition
-
- timezone 'Europe/Prague' do |tz|
- tz.offset :o0, 3464, 0, :LMT
- tz.offset :o1, 3464, 0, :PMT
- tz.offset :o2, 3600, 0, :CET
- tz.offset :o3, 3600, 3600, :CEST
-
- tz.transition 1849, 12, :o1, 25884991367, 10800
- tz.transition 1891, 9, :o2, 26049669767, 10800
- tz.transition 1916, 4, :o3, 29051813, 12
- tz.transition 1916, 9, :o2, 58107299, 24
- tz.transition 1917, 4, :o3, 58112029, 24
- tz.transition 1917, 9, :o2, 58115725, 24
- tz.transition 1918, 4, :o3, 58120765, 24
- tz.transition 1918, 9, :o2, 58124461, 24
- tz.transition 1940, 4, :o3, 58313293, 24
- tz.transition 1942, 11, :o2, 58335973, 24
- tz.transition 1943, 3, :o3, 58339501, 24
- tz.transition 1943, 10, :o2, 58344037, 24
- tz.transition 1944, 4, :o3, 58348405, 24
- tz.transition 1944, 9, :o2, 58352413, 24
- tz.transition 1945, 4, :o3, 58357285, 24
- tz.transition 1945, 11, :o2, 58362661, 24
- tz.transition 1946, 5, :o3, 58366717, 24
- tz.transition 1946, 10, :o2, 58370389, 24
- tz.transition 1947, 4, :o3, 58375093, 24
- tz.transition 1947, 10, :o2, 58379125, 24
- tz.transition 1948, 4, :o3, 58383829, 24
- tz.transition 1948, 10, :o2, 58387861, 24
- tz.transition 1949, 4, :o3, 58392373, 24
- tz.transition 1949, 10, :o2, 58396597, 24
- tz.transition 1979, 4, :o3, 291776400
- tz.transition 1979, 9, :o2, 307501200
- tz.transition 1980, 4, :o3, 323830800
- tz.transition 1980, 9, :o2, 338950800
- tz.transition 1981, 3, :o3, 354675600
- tz.transition 1981, 9, :o2, 370400400
- tz.transition 1982, 3, :o3, 386125200
- tz.transition 1982, 9, :o2, 401850000
- tz.transition 1983, 3, :o3, 417574800
- tz.transition 1983, 9, :o2, 433299600
- tz.transition 1984, 3, :o3, 449024400
- tz.transition 1984, 9, :o2, 465354000
- tz.transition 1985, 3, :o3, 481078800
- tz.transition 1985, 9, :o2, 496803600
- tz.transition 1986, 3, :o3, 512528400
- tz.transition 1986, 9, :o2, 528253200
- tz.transition 1987, 3, :o3, 543978000
- tz.transition 1987, 9, :o2, 559702800
- tz.transition 1988, 3, :o3, 575427600
- tz.transition 1988, 9, :o2, 591152400
- tz.transition 1989, 3, :o3, 606877200
- tz.transition 1989, 9, :o2, 622602000
- tz.transition 1990, 3, :o3, 638326800
- tz.transition 1990, 9, :o2, 654656400
- tz.transition 1991, 3, :o3, 670381200
- tz.transition 1991, 9, :o2, 686106000
- tz.transition 1992, 3, :o3, 701830800
- tz.transition 1992, 9, :o2, 717555600
- tz.transition 1993, 3, :o3, 733280400
- tz.transition 1993, 9, :o2, 749005200
- tz.transition 1994, 3, :o3, 764730000
- tz.transition 1994, 9, :o2, 780454800
- tz.transition 1995, 3, :o3, 796179600
- tz.transition 1995, 9, :o2, 811904400
- tz.transition 1996, 3, :o3, 828234000
- tz.transition 1996, 10, :o2, 846378000
- tz.transition 1997, 3, :o3, 859683600
- tz.transition 1997, 10, :o2, 877827600
- tz.transition 1998, 3, :o3, 891133200
- tz.transition 1998, 10, :o2, 909277200
- tz.transition 1999, 3, :o3, 922582800
- tz.transition 1999, 10, :o2, 941331600
- tz.transition 2000, 3, :o3, 954032400
- tz.transition 2000, 10, :o2, 972781200
- tz.transition 2001, 3, :o3, 985482000
- tz.transition 2001, 10, :o2, 1004230800
- tz.transition 2002, 3, :o3, 1017536400
- tz.transition 2002, 10, :o2, 1035680400
- tz.transition 2003, 3, :o3, 1048986000
- tz.transition 2003, 10, :o2, 1067130000
- tz.transition 2004, 3, :o3, 1080435600
- tz.transition 2004, 10, :o2, 1099184400
- tz.transition 2005, 3, :o3, 1111885200
- tz.transition 2005, 10, :o2, 1130634000
- tz.transition 2006, 3, :o3, 1143334800
- tz.transition 2006, 10, :o2, 1162083600
- tz.transition 2007, 3, :o3, 1174784400
- tz.transition 2007, 10, :o2, 1193533200
- tz.transition 2008, 3, :o3, 1206838800
- tz.transition 2008, 10, :o2, 1224982800
- tz.transition 2009, 3, :o3, 1238288400
- tz.transition 2009, 10, :o2, 1256432400
- tz.transition 2010, 3, :o3, 1269738000
- tz.transition 2010, 10, :o2, 1288486800
- tz.transition 2011, 3, :o3, 1301187600
- tz.transition 2011, 10, :o2, 1319936400
- tz.transition 2012, 3, :o3, 1332637200
- tz.transition 2012, 10, :o2, 1351386000
- tz.transition 2013, 3, :o3, 1364691600
- tz.transition 2013, 10, :o2, 1382835600
- tz.transition 2014, 3, :o3, 1396141200
- tz.transition 2014, 10, :o2, 1414285200
- tz.transition 2015, 3, :o3, 1427590800
- tz.transition 2015, 10, :o2, 1445734800
- tz.transition 2016, 3, :o3, 1459040400
- tz.transition 2016, 10, :o2, 1477789200
- tz.transition 2017, 3, :o3, 1490490000
- tz.transition 2017, 10, :o2, 1509238800
- tz.transition 2018, 3, :o3, 1521939600
- tz.transition 2018, 10, :o2, 1540688400
- tz.transition 2019, 3, :o3, 1553994000
- tz.transition 2019, 10, :o2, 1572138000
- tz.transition 2020, 3, :o3, 1585443600
- tz.transition 2020, 10, :o2, 1603587600
- tz.transition 2021, 3, :o3, 1616893200
- tz.transition 2021, 10, :o2, 1635642000
- tz.transition 2022, 3, :o3, 1648342800
- tz.transition 2022, 10, :o2, 1667091600
- tz.transition 2023, 3, :o3, 1679792400
- tz.transition 2023, 10, :o2, 1698541200
- tz.transition 2024, 3, :o3, 1711846800
- tz.transition 2024, 10, :o2, 1729990800
- tz.transition 2025, 3, :o3, 1743296400
- tz.transition 2025, 10, :o2, 1761440400
- tz.transition 2026, 3, :o3, 1774746000
- tz.transition 2026, 10, :o2, 1792890000
- tz.transition 2027, 3, :o3, 1806195600
- tz.transition 2027, 10, :o2, 1824944400
- tz.transition 2028, 3, :o3, 1837645200
- tz.transition 2028, 10, :o2, 1856394000
- tz.transition 2029, 3, :o3, 1869094800
- tz.transition 2029, 10, :o2, 1887843600
- tz.transition 2030, 3, :o3, 1901149200
- tz.transition 2030, 10, :o2, 1919293200
- tz.transition 2031, 3, :o3, 1932598800
- tz.transition 2031, 10, :o2, 1950742800
- tz.transition 2032, 3, :o3, 1964048400
- tz.transition 2032, 10, :o2, 1982797200
- tz.transition 2033, 3, :o3, 1995498000
- tz.transition 2033, 10, :o2, 2014246800
- tz.transition 2034, 3, :o3, 2026947600
- tz.transition 2034, 10, :o2, 2045696400
- tz.transition 2035, 3, :o3, 2058397200
- tz.transition 2035, 10, :o2, 2077146000
- tz.transition 2036, 3, :o3, 2090451600
- tz.transition 2036, 10, :o2, 2108595600
- tz.transition 2037, 3, :o3, 2121901200
- tz.transition 2037, 10, :o2, 2140045200
- tz.transition 2038, 3, :o3, 59172253, 24
- tz.transition 2038, 10, :o2, 59177461, 24
- tz.transition 2039, 3, :o3, 59180989, 24
- tz.transition 2039, 10, :o2, 59186197, 24
- tz.transition 2040, 3, :o3, 59189725, 24
- tz.transition 2040, 10, :o2, 59194933, 24
- tz.transition 2041, 3, :o3, 59198629, 24
- tz.transition 2041, 10, :o2, 59203669, 24
- tz.transition 2042, 3, :o3, 59207365, 24
- tz.transition 2042, 10, :o2, 59212405, 24
- tz.transition 2043, 3, :o3, 59216101, 24
- tz.transition 2043, 10, :o2, 59221141, 24
- tz.transition 2044, 3, :o3, 59224837, 24
- tz.transition 2044, 10, :o2, 59230045, 24
- tz.transition 2045, 3, :o3, 59233573, 24
- tz.transition 2045, 10, :o2, 59238781, 24
- tz.transition 2046, 3, :o3, 59242309, 24
- tz.transition 2046, 10, :o2, 59247517, 24
- tz.transition 2047, 3, :o3, 59251213, 24
- tz.transition 2047, 10, :o2, 59256253, 24
- tz.transition 2048, 3, :o3, 59259949, 24
- tz.transition 2048, 10, :o2, 59264989, 24
- tz.transition 2049, 3, :o3, 59268685, 24
- tz.transition 2049, 10, :o2, 59273893, 24
- tz.transition 2050, 3, :o3, 59277421, 24
- tz.transition 2050, 10, :o2, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Riga.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Riga.rb
deleted file mode 100644
index 784837f758..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Riga.rb
+++ /dev/null
@@ -1,176 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Riga
- include TimezoneDefinition
-
- timezone 'Europe/Riga' do |tz|
- tz.offset :o0, 5784, 0, :LMT
- tz.offset :o1, 5784, 0, :RMT
- tz.offset :o2, 5784, 3600, :LST
- tz.offset :o3, 7200, 0, :EET
- tz.offset :o4, 10800, 0, :MSK
- tz.offset :o5, 3600, 3600, :CEST
- tz.offset :o6, 3600, 0, :CET
- tz.offset :o7, 10800, 3600, :MSD
- tz.offset :o8, 7200, 3600, :EEST
-
- tz.transition 1879, 12, :o1, 8667775559, 3600
- tz.transition 1918, 4, :o2, 8718114659, 3600
- tz.transition 1918, 9, :o1, 8718669059, 3600
- tz.transition 1919, 4, :o2, 8719378259, 3600
- tz.transition 1919, 5, :o1, 8719561859, 3600
- tz.transition 1926, 5, :o3, 8728727159, 3600
- tz.transition 1940, 8, :o4, 29158157, 12
- tz.transition 1941, 6, :o5, 19441411, 8
- tz.transition 1942, 11, :o6, 58335973, 24
- tz.transition 1943, 3, :o5, 58339501, 24
- tz.transition 1943, 10, :o6, 58344037, 24
- tz.transition 1944, 4, :o5, 58348405, 24
- tz.transition 1944, 10, :o6, 58352773, 24
- tz.transition 1944, 10, :o4, 58353035, 24
- tz.transition 1981, 3, :o7, 354920400
- tz.transition 1981, 9, :o4, 370728000
- tz.transition 1982, 3, :o7, 386456400
- tz.transition 1982, 9, :o4, 402264000
- tz.transition 1983, 3, :o7, 417992400
- tz.transition 1983, 9, :o4, 433800000
- tz.transition 1984, 3, :o7, 449614800
- tz.transition 1984, 9, :o4, 465346800
- tz.transition 1985, 3, :o7, 481071600
- tz.transition 1985, 9, :o4, 496796400
- tz.transition 1986, 3, :o7, 512521200
- tz.transition 1986, 9, :o4, 528246000
- tz.transition 1987, 3, :o7, 543970800
- tz.transition 1987, 9, :o4, 559695600
- tz.transition 1988, 3, :o7, 575420400
- tz.transition 1988, 9, :o4, 591145200
- tz.transition 1989, 3, :o8, 606870000
- tz.transition 1989, 9, :o3, 622598400
- tz.transition 1990, 3, :o8, 638323200
- tz.transition 1990, 9, :o3, 654652800
- tz.transition 1991, 3, :o8, 670377600
- tz.transition 1991, 9, :o3, 686102400
- tz.transition 1992, 3, :o8, 701827200
- tz.transition 1992, 9, :o3, 717552000
- tz.transition 1993, 3, :o8, 733276800
- tz.transition 1993, 9, :o3, 749001600
- tz.transition 1994, 3, :o8, 764726400
- tz.transition 1994, 9, :o3, 780451200
- tz.transition 1995, 3, :o8, 796176000
- tz.transition 1995, 9, :o3, 811900800
- tz.transition 1996, 3, :o8, 828230400
- tz.transition 1996, 9, :o3, 843955200
- tz.transition 1997, 3, :o8, 859683600
- tz.transition 1997, 10, :o3, 877827600
- tz.transition 1998, 3, :o8, 891133200
- tz.transition 1998, 10, :o3, 909277200
- tz.transition 1999, 3, :o8, 922582800
- tz.transition 1999, 10, :o3, 941331600
- tz.transition 2001, 3, :o8, 985482000
- tz.transition 2001, 10, :o3, 1004230800
- tz.transition 2002, 3, :o8, 1017536400
- tz.transition 2002, 10, :o3, 1035680400
- tz.transition 2003, 3, :o8, 1048986000
- tz.transition 2003, 10, :o3, 1067130000
- tz.transition 2004, 3, :o8, 1080435600
- tz.transition 2004, 10, :o3, 1099184400
- tz.transition 2005, 3, :o8, 1111885200
- tz.transition 2005, 10, :o3, 1130634000
- tz.transition 2006, 3, :o8, 1143334800
- tz.transition 2006, 10, :o3, 1162083600
- tz.transition 2007, 3, :o8, 1174784400
- tz.transition 2007, 10, :o3, 1193533200
- tz.transition 2008, 3, :o8, 1206838800
- tz.transition 2008, 10, :o3, 1224982800
- tz.transition 2009, 3, :o8, 1238288400
- tz.transition 2009, 10, :o3, 1256432400
- tz.transition 2010, 3, :o8, 1269738000
- tz.transition 2010, 10, :o3, 1288486800
- tz.transition 2011, 3, :o8, 1301187600
- tz.transition 2011, 10, :o3, 1319936400
- tz.transition 2012, 3, :o8, 1332637200
- tz.transition 2012, 10, :o3, 1351386000
- tz.transition 2013, 3, :o8, 1364691600
- tz.transition 2013, 10, :o3, 1382835600
- tz.transition 2014, 3, :o8, 1396141200
- tz.transition 2014, 10, :o3, 1414285200
- tz.transition 2015, 3, :o8, 1427590800
- tz.transition 2015, 10, :o3, 1445734800
- tz.transition 2016, 3, :o8, 1459040400
- tz.transition 2016, 10, :o3, 1477789200
- tz.transition 2017, 3, :o8, 1490490000
- tz.transition 2017, 10, :o3, 1509238800
- tz.transition 2018, 3, :o8, 1521939600
- tz.transition 2018, 10, :o3, 1540688400
- tz.transition 2019, 3, :o8, 1553994000
- tz.transition 2019, 10, :o3, 1572138000
- tz.transition 2020, 3, :o8, 1585443600
- tz.transition 2020, 10, :o3, 1603587600
- tz.transition 2021, 3, :o8, 1616893200
- tz.transition 2021, 10, :o3, 1635642000
- tz.transition 2022, 3, :o8, 1648342800
- tz.transition 2022, 10, :o3, 1667091600
- tz.transition 2023, 3, :o8, 1679792400
- tz.transition 2023, 10, :o3, 1698541200
- tz.transition 2024, 3, :o8, 1711846800
- tz.transition 2024, 10, :o3, 1729990800
- tz.transition 2025, 3, :o8, 1743296400
- tz.transition 2025, 10, :o3, 1761440400
- tz.transition 2026, 3, :o8, 1774746000
- tz.transition 2026, 10, :o3, 1792890000
- tz.transition 2027, 3, :o8, 1806195600
- tz.transition 2027, 10, :o3, 1824944400
- tz.transition 2028, 3, :o8, 1837645200
- tz.transition 2028, 10, :o3, 1856394000
- tz.transition 2029, 3, :o8, 1869094800
- tz.transition 2029, 10, :o3, 1887843600
- tz.transition 2030, 3, :o8, 1901149200
- tz.transition 2030, 10, :o3, 1919293200
- tz.transition 2031, 3, :o8, 1932598800
- tz.transition 2031, 10, :o3, 1950742800
- tz.transition 2032, 3, :o8, 1964048400
- tz.transition 2032, 10, :o3, 1982797200
- tz.transition 2033, 3, :o8, 1995498000
- tz.transition 2033, 10, :o3, 2014246800
- tz.transition 2034, 3, :o8, 2026947600
- tz.transition 2034, 10, :o3, 2045696400
- tz.transition 2035, 3, :o8, 2058397200
- tz.transition 2035, 10, :o3, 2077146000
- tz.transition 2036, 3, :o8, 2090451600
- tz.transition 2036, 10, :o3, 2108595600
- tz.transition 2037, 3, :o8, 2121901200
- tz.transition 2037, 10, :o3, 2140045200
- tz.transition 2038, 3, :o8, 59172253, 24
- tz.transition 2038, 10, :o3, 59177461, 24
- tz.transition 2039, 3, :o8, 59180989, 24
- tz.transition 2039, 10, :o3, 59186197, 24
- tz.transition 2040, 3, :o8, 59189725, 24
- tz.transition 2040, 10, :o3, 59194933, 24
- tz.transition 2041, 3, :o8, 59198629, 24
- tz.transition 2041, 10, :o3, 59203669, 24
- tz.transition 2042, 3, :o8, 59207365, 24
- tz.transition 2042, 10, :o3, 59212405, 24
- tz.transition 2043, 3, :o8, 59216101, 24
- tz.transition 2043, 10, :o3, 59221141, 24
- tz.transition 2044, 3, :o8, 59224837, 24
- tz.transition 2044, 10, :o3, 59230045, 24
- tz.transition 2045, 3, :o8, 59233573, 24
- tz.transition 2045, 10, :o3, 59238781, 24
- tz.transition 2046, 3, :o8, 59242309, 24
- tz.transition 2046, 10, :o3, 59247517, 24
- tz.transition 2047, 3, :o8, 59251213, 24
- tz.transition 2047, 10, :o3, 59256253, 24
- tz.transition 2048, 3, :o8, 59259949, 24
- tz.transition 2048, 10, :o3, 59264989, 24
- tz.transition 2049, 3, :o8, 59268685, 24
- tz.transition 2049, 10, :o3, 59273893, 24
- tz.transition 2050, 3, :o8, 59277421, 24
- tz.transition 2050, 10, :o3, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Rome.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Rome.rb
deleted file mode 100644
index aa7b43d9d2..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Rome.rb
+++ /dev/null
@@ -1,215 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Rome
- include TimezoneDefinition
-
- timezone 'Europe/Rome' do |tz|
- tz.offset :o0, 2996, 0, :LMT
- tz.offset :o1, 2996, 0, :RMT
- tz.offset :o2, 3600, 0, :CET
- tz.offset :o3, 3600, 3600, :CEST
-
- tz.transition 1866, 9, :o1, 51901915651, 21600
- tz.transition 1893, 10, :o2, 52115798851, 21600
- tz.transition 1916, 6, :o3, 58104419, 24
- tz.transition 1916, 9, :o2, 58107299, 24
- tz.transition 1917, 3, :o3, 58111667, 24
- tz.transition 1917, 9, :o2, 58116035, 24
- tz.transition 1918, 3, :o3, 58119899, 24
- tz.transition 1918, 10, :o2, 58124939, 24
- tz.transition 1919, 3, :o3, 58128467, 24
- tz.transition 1919, 10, :o2, 58133675, 24
- tz.transition 1920, 3, :o3, 58137707, 24
- tz.transition 1920, 9, :o2, 58142075, 24
- tz.transition 1940, 6, :o3, 58315091, 24
- tz.transition 1942, 11, :o2, 58335973, 24
- tz.transition 1943, 3, :o3, 58339501, 24
- tz.transition 1943, 10, :o2, 58344037, 24
- tz.transition 1944, 4, :o3, 58348405, 24
- tz.transition 1944, 9, :o2, 58352411, 24
- tz.transition 1945, 4, :o3, 58357141, 24
- tz.transition 1945, 9, :o2, 58361123, 24
- tz.transition 1946, 3, :o3, 58365517, 24
- tz.transition 1946, 10, :o2, 58370389, 24
- tz.transition 1947, 3, :o3, 58374251, 24
- tz.transition 1947, 10, :o2, 58379123, 24
- tz.transition 1948, 2, :o3, 58382653, 24
- tz.transition 1948, 10, :o2, 58387861, 24
- tz.transition 1966, 5, :o3, 58542419, 24
- tz.transition 1966, 9, :o2, 29272721, 12
- tz.transition 1967, 5, :o3, 58551323, 24
- tz.transition 1967, 9, :o2, 29277089, 12
- tz.transition 1968, 5, :o3, 58560059, 24
- tz.transition 1968, 9, :o2, 29281457, 12
- tz.transition 1969, 5, :o3, 58568963, 24
- tz.transition 1969, 9, :o2, 29285909, 12
- tz.transition 1970, 5, :o3, 12956400
- tz.transition 1970, 9, :o2, 23234400
- tz.transition 1971, 5, :o3, 43801200
- tz.transition 1971, 9, :o2, 54687600
- tz.transition 1972, 5, :o3, 75855600
- tz.transition 1972, 9, :o2, 86738400
- tz.transition 1973, 6, :o3, 107910000
- tz.transition 1973, 9, :o2, 118188000
- tz.transition 1974, 5, :o3, 138754800
- tz.transition 1974, 9, :o2, 149637600
- tz.transition 1975, 5, :o3, 170809200
- tz.transition 1975, 9, :o2, 181090800
- tz.transition 1976, 5, :o3, 202258800
- tz.transition 1976, 9, :o2, 212540400
- tz.transition 1977, 5, :o3, 233103600
- tz.transition 1977, 9, :o2, 243990000
- tz.transition 1978, 5, :o3, 265158000
- tz.transition 1978, 9, :o2, 276044400
- tz.transition 1979, 5, :o3, 296607600
- tz.transition 1979, 9, :o2, 307494000
- tz.transition 1980, 4, :o3, 323830800
- tz.transition 1980, 9, :o2, 338950800
- tz.transition 1981, 3, :o3, 354675600
- tz.transition 1981, 9, :o2, 370400400
- tz.transition 1982, 3, :o3, 386125200
- tz.transition 1982, 9, :o2, 401850000
- tz.transition 1983, 3, :o3, 417574800
- tz.transition 1983, 9, :o2, 433299600
- tz.transition 1984, 3, :o3, 449024400
- tz.transition 1984, 9, :o2, 465354000
- tz.transition 1985, 3, :o3, 481078800
- tz.transition 1985, 9, :o2, 496803600
- tz.transition 1986, 3, :o3, 512528400
- tz.transition 1986, 9, :o2, 528253200
- tz.transition 1987, 3, :o3, 543978000
- tz.transition 1987, 9, :o2, 559702800
- tz.transition 1988, 3, :o3, 575427600
- tz.transition 1988, 9, :o2, 591152400
- tz.transition 1989, 3, :o3, 606877200
- tz.transition 1989, 9, :o2, 622602000
- tz.transition 1990, 3, :o3, 638326800
- tz.transition 1990, 9, :o2, 654656400
- tz.transition 1991, 3, :o3, 670381200
- tz.transition 1991, 9, :o2, 686106000
- tz.transition 1992, 3, :o3, 701830800
- tz.transition 1992, 9, :o2, 717555600
- tz.transition 1993, 3, :o3, 733280400
- tz.transition 1993, 9, :o2, 749005200
- tz.transition 1994, 3, :o3, 764730000
- tz.transition 1994, 9, :o2, 780454800
- tz.transition 1995, 3, :o3, 796179600
- tz.transition 1995, 9, :o2, 811904400
- tz.transition 1996, 3, :o3, 828234000
- tz.transition 1996, 10, :o2, 846378000
- tz.transition 1997, 3, :o3, 859683600
- tz.transition 1997, 10, :o2, 877827600
- tz.transition 1998, 3, :o3, 891133200
- tz.transition 1998, 10, :o2, 909277200
- tz.transition 1999, 3, :o3, 922582800
- tz.transition 1999, 10, :o2, 941331600
- tz.transition 2000, 3, :o3, 954032400
- tz.transition 2000, 10, :o2, 972781200
- tz.transition 2001, 3, :o3, 985482000
- tz.transition 2001, 10, :o2, 1004230800
- tz.transition 2002, 3, :o3, 1017536400
- tz.transition 2002, 10, :o2, 1035680400
- tz.transition 2003, 3, :o3, 1048986000
- tz.transition 2003, 10, :o2, 1067130000
- tz.transition 2004, 3, :o3, 1080435600
- tz.transition 2004, 10, :o2, 1099184400
- tz.transition 2005, 3, :o3, 1111885200
- tz.transition 2005, 10, :o2, 1130634000
- tz.transition 2006, 3, :o3, 1143334800
- tz.transition 2006, 10, :o2, 1162083600
- tz.transition 2007, 3, :o3, 1174784400
- tz.transition 2007, 10, :o2, 1193533200
- tz.transition 2008, 3, :o3, 1206838800
- tz.transition 2008, 10, :o2, 1224982800
- tz.transition 2009, 3, :o3, 1238288400
- tz.transition 2009, 10, :o2, 1256432400
- tz.transition 2010, 3, :o3, 1269738000
- tz.transition 2010, 10, :o2, 1288486800
- tz.transition 2011, 3, :o3, 1301187600
- tz.transition 2011, 10, :o2, 1319936400
- tz.transition 2012, 3, :o3, 1332637200
- tz.transition 2012, 10, :o2, 1351386000
- tz.transition 2013, 3, :o3, 1364691600
- tz.transition 2013, 10, :o2, 1382835600
- tz.transition 2014, 3, :o3, 1396141200
- tz.transition 2014, 10, :o2, 1414285200
- tz.transition 2015, 3, :o3, 1427590800
- tz.transition 2015, 10, :o2, 1445734800
- tz.transition 2016, 3, :o3, 1459040400
- tz.transition 2016, 10, :o2, 1477789200
- tz.transition 2017, 3, :o3, 1490490000
- tz.transition 2017, 10, :o2, 1509238800
- tz.transition 2018, 3, :o3, 1521939600
- tz.transition 2018, 10, :o2, 1540688400
- tz.transition 2019, 3, :o3, 1553994000
- tz.transition 2019, 10, :o2, 1572138000
- tz.transition 2020, 3, :o3, 1585443600
- tz.transition 2020, 10, :o2, 1603587600
- tz.transition 2021, 3, :o3, 1616893200
- tz.transition 2021, 10, :o2, 1635642000
- tz.transition 2022, 3, :o3, 1648342800
- tz.transition 2022, 10, :o2, 1667091600
- tz.transition 2023, 3, :o3, 1679792400
- tz.transition 2023, 10, :o2, 1698541200
- tz.transition 2024, 3, :o3, 1711846800
- tz.transition 2024, 10, :o2, 1729990800
- tz.transition 2025, 3, :o3, 1743296400
- tz.transition 2025, 10, :o2, 1761440400
- tz.transition 2026, 3, :o3, 1774746000
- tz.transition 2026, 10, :o2, 1792890000
- tz.transition 2027, 3, :o3, 1806195600
- tz.transition 2027, 10, :o2, 1824944400
- tz.transition 2028, 3, :o3, 1837645200
- tz.transition 2028, 10, :o2, 1856394000
- tz.transition 2029, 3, :o3, 1869094800
- tz.transition 2029, 10, :o2, 1887843600
- tz.transition 2030, 3, :o3, 1901149200
- tz.transition 2030, 10, :o2, 1919293200
- tz.transition 2031, 3, :o3, 1932598800
- tz.transition 2031, 10, :o2, 1950742800
- tz.transition 2032, 3, :o3, 1964048400
- tz.transition 2032, 10, :o2, 1982797200
- tz.transition 2033, 3, :o3, 1995498000
- tz.transition 2033, 10, :o2, 2014246800
- tz.transition 2034, 3, :o3, 2026947600
- tz.transition 2034, 10, :o2, 2045696400
- tz.transition 2035, 3, :o3, 2058397200
- tz.transition 2035, 10, :o2, 2077146000
- tz.transition 2036, 3, :o3, 2090451600
- tz.transition 2036, 10, :o2, 2108595600
- tz.transition 2037, 3, :o3, 2121901200
- tz.transition 2037, 10, :o2, 2140045200
- tz.transition 2038, 3, :o3, 59172253, 24
- tz.transition 2038, 10, :o2, 59177461, 24
- tz.transition 2039, 3, :o3, 59180989, 24
- tz.transition 2039, 10, :o2, 59186197, 24
- tz.transition 2040, 3, :o3, 59189725, 24
- tz.transition 2040, 10, :o2, 59194933, 24
- tz.transition 2041, 3, :o3, 59198629, 24
- tz.transition 2041, 10, :o2, 59203669, 24
- tz.transition 2042, 3, :o3, 59207365, 24
- tz.transition 2042, 10, :o2, 59212405, 24
- tz.transition 2043, 3, :o3, 59216101, 24
- tz.transition 2043, 10, :o2, 59221141, 24
- tz.transition 2044, 3, :o3, 59224837, 24
- tz.transition 2044, 10, :o2, 59230045, 24
- tz.transition 2045, 3, :o3, 59233573, 24
- tz.transition 2045, 10, :o2, 59238781, 24
- tz.transition 2046, 3, :o3, 59242309, 24
- tz.transition 2046, 10, :o2, 59247517, 24
- tz.transition 2047, 3, :o3, 59251213, 24
- tz.transition 2047, 10, :o2, 59256253, 24
- tz.transition 2048, 3, :o3, 59259949, 24
- tz.transition 2048, 10, :o2, 59264989, 24
- tz.transition 2049, 3, :o3, 59268685, 24
- tz.transition 2049, 10, :o2, 59273893, 24
- tz.transition 2050, 3, :o3, 59277421, 24
- tz.transition 2050, 10, :o2, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Sarajevo.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Sarajevo.rb
deleted file mode 100644
index 068c5fe6ad..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Sarajevo.rb
+++ /dev/null
@@ -1,13 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Sarajevo
- include TimezoneDefinition
-
- linked_timezone 'Europe/Sarajevo', 'Europe/Belgrade'
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Skopje.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Skopje.rb
deleted file mode 100644
index 10b71f285e..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Skopje.rb
+++ /dev/null
@@ -1,13 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Skopje
- include TimezoneDefinition
-
- linked_timezone 'Europe/Skopje', 'Europe/Belgrade'
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Sofia.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Sofia.rb
deleted file mode 100644
index 38a70eceb9..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Sofia.rb
+++ /dev/null
@@ -1,173 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Sofia
- include TimezoneDefinition
-
- timezone 'Europe/Sofia' do |tz|
- tz.offset :o0, 5596, 0, :LMT
- tz.offset :o1, 7016, 0, :IMT
- tz.offset :o2, 7200, 0, :EET
- tz.offset :o3, 3600, 0, :CET
- tz.offset :o4, 3600, 3600, :CEST
- tz.offset :o5, 7200, 3600, :EEST
-
- tz.transition 1879, 12, :o1, 52006653401, 21600
- tz.transition 1894, 11, :o2, 26062154123, 10800
- tz.transition 1942, 11, :o3, 58335973, 24
- tz.transition 1943, 3, :o4, 58339501, 24
- tz.transition 1943, 10, :o3, 58344037, 24
- tz.transition 1944, 4, :o4, 58348405, 24
- tz.transition 1944, 10, :o3, 58352773, 24
- tz.transition 1945, 4, :o2, 29178571, 12
- tz.transition 1979, 3, :o5, 291762000
- tz.transition 1979, 9, :o2, 307576800
- tz.transition 1980, 4, :o5, 323816400
- tz.transition 1980, 9, :o2, 339026400
- tz.transition 1981, 4, :o5, 355266000
- tz.transition 1981, 9, :o2, 370393200
- tz.transition 1982, 4, :o5, 386715600
- tz.transition 1982, 9, :o2, 401846400
- tz.transition 1983, 3, :o5, 417571200
- tz.transition 1983, 9, :o2, 433296000
- tz.transition 1984, 3, :o5, 449020800
- tz.transition 1984, 9, :o2, 465350400
- tz.transition 1985, 3, :o5, 481075200
- tz.transition 1985, 9, :o2, 496800000
- tz.transition 1986, 3, :o5, 512524800
- tz.transition 1986, 9, :o2, 528249600
- tz.transition 1987, 3, :o5, 543974400
- tz.transition 1987, 9, :o2, 559699200
- tz.transition 1988, 3, :o5, 575424000
- tz.transition 1988, 9, :o2, 591148800
- tz.transition 1989, 3, :o5, 606873600
- tz.transition 1989, 9, :o2, 622598400
- tz.transition 1990, 3, :o5, 638323200
- tz.transition 1990, 9, :o2, 654652800
- tz.transition 1991, 3, :o5, 670370400
- tz.transition 1991, 9, :o2, 686091600
- tz.transition 1992, 3, :o5, 701820000
- tz.transition 1992, 9, :o2, 717541200
- tz.transition 1993, 3, :o5, 733269600
- tz.transition 1993, 9, :o2, 748990800
- tz.transition 1994, 3, :o5, 764719200
- tz.transition 1994, 9, :o2, 780440400
- tz.transition 1995, 3, :o5, 796168800
- tz.transition 1995, 9, :o2, 811890000
- tz.transition 1996, 3, :o5, 828223200
- tz.transition 1996, 10, :o2, 846363600
- tz.transition 1997, 3, :o5, 859683600
- tz.transition 1997, 10, :o2, 877827600
- tz.transition 1998, 3, :o5, 891133200
- tz.transition 1998, 10, :o2, 909277200
- tz.transition 1999, 3, :o5, 922582800
- tz.transition 1999, 10, :o2, 941331600
- tz.transition 2000, 3, :o5, 954032400
- tz.transition 2000, 10, :o2, 972781200
- tz.transition 2001, 3, :o5, 985482000
- tz.transition 2001, 10, :o2, 1004230800
- tz.transition 2002, 3, :o5, 1017536400
- tz.transition 2002, 10, :o2, 1035680400
- tz.transition 2003, 3, :o5, 1048986000
- tz.transition 2003, 10, :o2, 1067130000
- tz.transition 2004, 3, :o5, 1080435600
- tz.transition 2004, 10, :o2, 1099184400
- tz.transition 2005, 3, :o5, 1111885200
- tz.transition 2005, 10, :o2, 1130634000
- tz.transition 2006, 3, :o5, 1143334800
- tz.transition 2006, 10, :o2, 1162083600
- tz.transition 2007, 3, :o5, 1174784400
- tz.transition 2007, 10, :o2, 1193533200
- tz.transition 2008, 3, :o5, 1206838800
- tz.transition 2008, 10, :o2, 1224982800
- tz.transition 2009, 3, :o5, 1238288400
- tz.transition 2009, 10, :o2, 1256432400
- tz.transition 2010, 3, :o5, 1269738000
- tz.transition 2010, 10, :o2, 1288486800
- tz.transition 2011, 3, :o5, 1301187600
- tz.transition 2011, 10, :o2, 1319936400
- tz.transition 2012, 3, :o5, 1332637200
- tz.transition 2012, 10, :o2, 1351386000
- tz.transition 2013, 3, :o5, 1364691600
- tz.transition 2013, 10, :o2, 1382835600
- tz.transition 2014, 3, :o5, 1396141200
- tz.transition 2014, 10, :o2, 1414285200
- tz.transition 2015, 3, :o5, 1427590800
- tz.transition 2015, 10, :o2, 1445734800
- tz.transition 2016, 3, :o5, 1459040400
- tz.transition 2016, 10, :o2, 1477789200
- tz.transition 2017, 3, :o5, 1490490000
- tz.transition 2017, 10, :o2, 1509238800
- tz.transition 2018, 3, :o5, 1521939600
- tz.transition 2018, 10, :o2, 1540688400
- tz.transition 2019, 3, :o5, 1553994000
- tz.transition 2019, 10, :o2, 1572138000
- tz.transition 2020, 3, :o5, 1585443600
- tz.transition 2020, 10, :o2, 1603587600
- tz.transition 2021, 3, :o5, 1616893200
- tz.transition 2021, 10, :o2, 1635642000
- tz.transition 2022, 3, :o5, 1648342800
- tz.transition 2022, 10, :o2, 1667091600
- tz.transition 2023, 3, :o5, 1679792400
- tz.transition 2023, 10, :o2, 1698541200
- tz.transition 2024, 3, :o5, 1711846800
- tz.transition 2024, 10, :o2, 1729990800
- tz.transition 2025, 3, :o5, 1743296400
- tz.transition 2025, 10, :o2, 1761440400
- tz.transition 2026, 3, :o5, 1774746000
- tz.transition 2026, 10, :o2, 1792890000
- tz.transition 2027, 3, :o5, 1806195600
- tz.transition 2027, 10, :o2, 1824944400
- tz.transition 2028, 3, :o5, 1837645200
- tz.transition 2028, 10, :o2, 1856394000
- tz.transition 2029, 3, :o5, 1869094800
- tz.transition 2029, 10, :o2, 1887843600
- tz.transition 2030, 3, :o5, 1901149200
- tz.transition 2030, 10, :o2, 1919293200
- tz.transition 2031, 3, :o5, 1932598800
- tz.transition 2031, 10, :o2, 1950742800
- tz.transition 2032, 3, :o5, 1964048400
- tz.transition 2032, 10, :o2, 1982797200
- tz.transition 2033, 3, :o5, 1995498000
- tz.transition 2033, 10, :o2, 2014246800
- tz.transition 2034, 3, :o5, 2026947600
- tz.transition 2034, 10, :o2, 2045696400
- tz.transition 2035, 3, :o5, 2058397200
- tz.transition 2035, 10, :o2, 2077146000
- tz.transition 2036, 3, :o5, 2090451600
- tz.transition 2036, 10, :o2, 2108595600
- tz.transition 2037, 3, :o5, 2121901200
- tz.transition 2037, 10, :o2, 2140045200
- tz.transition 2038, 3, :o5, 59172253, 24
- tz.transition 2038, 10, :o2, 59177461, 24
- tz.transition 2039, 3, :o5, 59180989, 24
- tz.transition 2039, 10, :o2, 59186197, 24
- tz.transition 2040, 3, :o5, 59189725, 24
- tz.transition 2040, 10, :o2, 59194933, 24
- tz.transition 2041, 3, :o5, 59198629, 24
- tz.transition 2041, 10, :o2, 59203669, 24
- tz.transition 2042, 3, :o5, 59207365, 24
- tz.transition 2042, 10, :o2, 59212405, 24
- tz.transition 2043, 3, :o5, 59216101, 24
- tz.transition 2043, 10, :o2, 59221141, 24
- tz.transition 2044, 3, :o5, 59224837, 24
- tz.transition 2044, 10, :o2, 59230045, 24
- tz.transition 2045, 3, :o5, 59233573, 24
- tz.transition 2045, 10, :o2, 59238781, 24
- tz.transition 2046, 3, :o5, 59242309, 24
- tz.transition 2046, 10, :o2, 59247517, 24
- tz.transition 2047, 3, :o5, 59251213, 24
- tz.transition 2047, 10, :o2, 59256253, 24
- tz.transition 2048, 3, :o5, 59259949, 24
- tz.transition 2048, 10, :o2, 59264989, 24
- tz.transition 2049, 3, :o5, 59268685, 24
- tz.transition 2049, 10, :o2, 59273893, 24
- tz.transition 2050, 3, :o5, 59277421, 24
- tz.transition 2050, 10, :o2, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Stockholm.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Stockholm.rb
deleted file mode 100644
index 43db70fa61..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Stockholm.rb
+++ /dev/null
@@ -1,165 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Stockholm
- include TimezoneDefinition
-
- timezone 'Europe/Stockholm' do |tz|
- tz.offset :o0, 4332, 0, :LMT
- tz.offset :o1, 3614, 0, :SET
- tz.offset :o2, 3600, 0, :CET
- tz.offset :o3, 3600, 3600, :CEST
-
- tz.transition 1878, 12, :o1, 17332923239, 7200
- tz.transition 1899, 12, :o2, 104328883793, 43200
- tz.transition 1916, 5, :o3, 29051981, 12
- tz.transition 1916, 9, :o2, 58107299, 24
- tz.transition 1980, 4, :o3, 323830800
- tz.transition 1980, 9, :o2, 338950800
- tz.transition 1981, 3, :o3, 354675600
- tz.transition 1981, 9, :o2, 370400400
- tz.transition 1982, 3, :o3, 386125200
- tz.transition 1982, 9, :o2, 401850000
- tz.transition 1983, 3, :o3, 417574800
- tz.transition 1983, 9, :o2, 433299600
- tz.transition 1984, 3, :o3, 449024400
- tz.transition 1984, 9, :o2, 465354000
- tz.transition 1985, 3, :o3, 481078800
- tz.transition 1985, 9, :o2, 496803600
- tz.transition 1986, 3, :o3, 512528400
- tz.transition 1986, 9, :o2, 528253200
- tz.transition 1987, 3, :o3, 543978000
- tz.transition 1987, 9, :o2, 559702800
- tz.transition 1988, 3, :o3, 575427600
- tz.transition 1988, 9, :o2, 591152400
- tz.transition 1989, 3, :o3, 606877200
- tz.transition 1989, 9, :o2, 622602000
- tz.transition 1990, 3, :o3, 638326800
- tz.transition 1990, 9, :o2, 654656400
- tz.transition 1991, 3, :o3, 670381200
- tz.transition 1991, 9, :o2, 686106000
- tz.transition 1992, 3, :o3, 701830800
- tz.transition 1992, 9, :o2, 717555600
- tz.transition 1993, 3, :o3, 733280400
- tz.transition 1993, 9, :o2, 749005200
- tz.transition 1994, 3, :o3, 764730000
- tz.transition 1994, 9, :o2, 780454800
- tz.transition 1995, 3, :o3, 796179600
- tz.transition 1995, 9, :o2, 811904400
- tz.transition 1996, 3, :o3, 828234000
- tz.transition 1996, 10, :o2, 846378000
- tz.transition 1997, 3, :o3, 859683600
- tz.transition 1997, 10, :o2, 877827600
- tz.transition 1998, 3, :o3, 891133200
- tz.transition 1998, 10, :o2, 909277200
- tz.transition 1999, 3, :o3, 922582800
- tz.transition 1999, 10, :o2, 941331600
- tz.transition 2000, 3, :o3, 954032400
- tz.transition 2000, 10, :o2, 972781200
- tz.transition 2001, 3, :o3, 985482000
- tz.transition 2001, 10, :o2, 1004230800
- tz.transition 2002, 3, :o3, 1017536400
- tz.transition 2002, 10, :o2, 1035680400
- tz.transition 2003, 3, :o3, 1048986000
- tz.transition 2003, 10, :o2, 1067130000
- tz.transition 2004, 3, :o3, 1080435600
- tz.transition 2004, 10, :o2, 1099184400
- tz.transition 2005, 3, :o3, 1111885200
- tz.transition 2005, 10, :o2, 1130634000
- tz.transition 2006, 3, :o3, 1143334800
- tz.transition 2006, 10, :o2, 1162083600
- tz.transition 2007, 3, :o3, 1174784400
- tz.transition 2007, 10, :o2, 1193533200
- tz.transition 2008, 3, :o3, 1206838800
- tz.transition 2008, 10, :o2, 1224982800
- tz.transition 2009, 3, :o3, 1238288400
- tz.transition 2009, 10, :o2, 1256432400
- tz.transition 2010, 3, :o3, 1269738000
- tz.transition 2010, 10, :o2, 1288486800
- tz.transition 2011, 3, :o3, 1301187600
- tz.transition 2011, 10, :o2, 1319936400
- tz.transition 2012, 3, :o3, 1332637200
- tz.transition 2012, 10, :o2, 1351386000
- tz.transition 2013, 3, :o3, 1364691600
- tz.transition 2013, 10, :o2, 1382835600
- tz.transition 2014, 3, :o3, 1396141200
- tz.transition 2014, 10, :o2, 1414285200
- tz.transition 2015, 3, :o3, 1427590800
- tz.transition 2015, 10, :o2, 1445734800
- tz.transition 2016, 3, :o3, 1459040400
- tz.transition 2016, 10, :o2, 1477789200
- tz.transition 2017, 3, :o3, 1490490000
- tz.transition 2017, 10, :o2, 1509238800
- tz.transition 2018, 3, :o3, 1521939600
- tz.transition 2018, 10, :o2, 1540688400
- tz.transition 2019, 3, :o3, 1553994000
- tz.transition 2019, 10, :o2, 1572138000
- tz.transition 2020, 3, :o3, 1585443600
- tz.transition 2020, 10, :o2, 1603587600
- tz.transition 2021, 3, :o3, 1616893200
- tz.transition 2021, 10, :o2, 1635642000
- tz.transition 2022, 3, :o3, 1648342800
- tz.transition 2022, 10, :o2, 1667091600
- tz.transition 2023, 3, :o3, 1679792400
- tz.transition 2023, 10, :o2, 1698541200
- tz.transition 2024, 3, :o3, 1711846800
- tz.transition 2024, 10, :o2, 1729990800
- tz.transition 2025, 3, :o3, 1743296400
- tz.transition 2025, 10, :o2, 1761440400
- tz.transition 2026, 3, :o3, 1774746000
- tz.transition 2026, 10, :o2, 1792890000
- tz.transition 2027, 3, :o3, 1806195600
- tz.transition 2027, 10, :o2, 1824944400
- tz.transition 2028, 3, :o3, 1837645200
- tz.transition 2028, 10, :o2, 1856394000
- tz.transition 2029, 3, :o3, 1869094800
- tz.transition 2029, 10, :o2, 1887843600
- tz.transition 2030, 3, :o3, 1901149200
- tz.transition 2030, 10, :o2, 1919293200
- tz.transition 2031, 3, :o3, 1932598800
- tz.transition 2031, 10, :o2, 1950742800
- tz.transition 2032, 3, :o3, 1964048400
- tz.transition 2032, 10, :o2, 1982797200
- tz.transition 2033, 3, :o3, 1995498000
- tz.transition 2033, 10, :o2, 2014246800
- tz.transition 2034, 3, :o3, 2026947600
- tz.transition 2034, 10, :o2, 2045696400
- tz.transition 2035, 3, :o3, 2058397200
- tz.transition 2035, 10, :o2, 2077146000
- tz.transition 2036, 3, :o3, 2090451600
- tz.transition 2036, 10, :o2, 2108595600
- tz.transition 2037, 3, :o3, 2121901200
- tz.transition 2037, 10, :o2, 2140045200
- tz.transition 2038, 3, :o3, 59172253, 24
- tz.transition 2038, 10, :o2, 59177461, 24
- tz.transition 2039, 3, :o3, 59180989, 24
- tz.transition 2039, 10, :o2, 59186197, 24
- tz.transition 2040, 3, :o3, 59189725, 24
- tz.transition 2040, 10, :o2, 59194933, 24
- tz.transition 2041, 3, :o3, 59198629, 24
- tz.transition 2041, 10, :o2, 59203669, 24
- tz.transition 2042, 3, :o3, 59207365, 24
- tz.transition 2042, 10, :o2, 59212405, 24
- tz.transition 2043, 3, :o3, 59216101, 24
- tz.transition 2043, 10, :o2, 59221141, 24
- tz.transition 2044, 3, :o3, 59224837, 24
- tz.transition 2044, 10, :o2, 59230045, 24
- tz.transition 2045, 3, :o3, 59233573, 24
- tz.transition 2045, 10, :o2, 59238781, 24
- tz.transition 2046, 3, :o3, 59242309, 24
- tz.transition 2046, 10, :o2, 59247517, 24
- tz.transition 2047, 3, :o3, 59251213, 24
- tz.transition 2047, 10, :o2, 59256253, 24
- tz.transition 2048, 3, :o3, 59259949, 24
- tz.transition 2048, 10, :o2, 59264989, 24
- tz.transition 2049, 3, :o3, 59268685, 24
- tz.transition 2049, 10, :o2, 59273893, 24
- tz.transition 2050, 3, :o3, 59277421, 24
- tz.transition 2050, 10, :o2, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Tallinn.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Tallinn.rb
deleted file mode 100644
index de5a8569f3..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Tallinn.rb
+++ /dev/null
@@ -1,172 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Tallinn
- include TimezoneDefinition
-
- timezone 'Europe/Tallinn' do |tz|
- tz.offset :o0, 5940, 0, :LMT
- tz.offset :o1, 5940, 0, :TMT
- tz.offset :o2, 3600, 0, :CET
- tz.offset :o3, 3600, 3600, :CEST
- tz.offset :o4, 7200, 0, :EET
- tz.offset :o5, 10800, 0, :MSK
- tz.offset :o6, 10800, 3600, :MSD
- tz.offset :o7, 7200, 3600, :EEST
-
- tz.transition 1879, 12, :o1, 385234469, 160
- tz.transition 1918, 1, :o2, 387460069, 160
- tz.transition 1918, 4, :o3, 58120765, 24
- tz.transition 1918, 9, :o2, 58124461, 24
- tz.transition 1919, 6, :o1, 58131371, 24
- tz.transition 1921, 4, :o4, 387649669, 160
- tz.transition 1940, 8, :o5, 29158169, 12
- tz.transition 1941, 9, :o3, 19442019, 8
- tz.transition 1942, 11, :o2, 58335973, 24
- tz.transition 1943, 3, :o3, 58339501, 24
- tz.transition 1943, 10, :o2, 58344037, 24
- tz.transition 1944, 4, :o3, 58348405, 24
- tz.transition 1944, 9, :o5, 29176265, 12
- tz.transition 1981, 3, :o6, 354920400
- tz.transition 1981, 9, :o5, 370728000
- tz.transition 1982, 3, :o6, 386456400
- tz.transition 1982, 9, :o5, 402264000
- tz.transition 1983, 3, :o6, 417992400
- tz.transition 1983, 9, :o5, 433800000
- tz.transition 1984, 3, :o6, 449614800
- tz.transition 1984, 9, :o5, 465346800
- tz.transition 1985, 3, :o6, 481071600
- tz.transition 1985, 9, :o5, 496796400
- tz.transition 1986, 3, :o6, 512521200
- tz.transition 1986, 9, :o5, 528246000
- tz.transition 1987, 3, :o6, 543970800
- tz.transition 1987, 9, :o5, 559695600
- tz.transition 1988, 3, :o6, 575420400
- tz.transition 1988, 9, :o5, 591145200
- tz.transition 1989, 3, :o7, 606870000
- tz.transition 1989, 9, :o4, 622598400
- tz.transition 1990, 3, :o7, 638323200
- tz.transition 1990, 9, :o4, 654652800
- tz.transition 1991, 3, :o7, 670377600
- tz.transition 1991, 9, :o4, 686102400
- tz.transition 1992, 3, :o7, 701827200
- tz.transition 1992, 9, :o4, 717552000
- tz.transition 1993, 3, :o7, 733276800
- tz.transition 1993, 9, :o4, 749001600
- tz.transition 1994, 3, :o7, 764726400
- tz.transition 1994, 9, :o4, 780451200
- tz.transition 1995, 3, :o7, 796176000
- tz.transition 1995, 9, :o4, 811900800
- tz.transition 1996, 3, :o7, 828230400
- tz.transition 1996, 10, :o4, 846374400
- tz.transition 1997, 3, :o7, 859680000
- tz.transition 1997, 10, :o4, 877824000
- tz.transition 1998, 3, :o7, 891129600
- tz.transition 1998, 10, :o4, 909277200
- tz.transition 1999, 3, :o7, 922582800
- tz.transition 1999, 10, :o4, 941331600
- tz.transition 2002, 3, :o7, 1017536400
- tz.transition 2002, 10, :o4, 1035680400
- tz.transition 2003, 3, :o7, 1048986000
- tz.transition 2003, 10, :o4, 1067130000
- tz.transition 2004, 3, :o7, 1080435600
- tz.transition 2004, 10, :o4, 1099184400
- tz.transition 2005, 3, :o7, 1111885200
- tz.transition 2005, 10, :o4, 1130634000
- tz.transition 2006, 3, :o7, 1143334800
- tz.transition 2006, 10, :o4, 1162083600
- tz.transition 2007, 3, :o7, 1174784400
- tz.transition 2007, 10, :o4, 1193533200
- tz.transition 2008, 3, :o7, 1206838800
- tz.transition 2008, 10, :o4, 1224982800
- tz.transition 2009, 3, :o7, 1238288400
- tz.transition 2009, 10, :o4, 1256432400
- tz.transition 2010, 3, :o7, 1269738000
- tz.transition 2010, 10, :o4, 1288486800
- tz.transition 2011, 3, :o7, 1301187600
- tz.transition 2011, 10, :o4, 1319936400
- tz.transition 2012, 3, :o7, 1332637200
- tz.transition 2012, 10, :o4, 1351386000
- tz.transition 2013, 3, :o7, 1364691600
- tz.transition 2013, 10, :o4, 1382835600
- tz.transition 2014, 3, :o7, 1396141200
- tz.transition 2014, 10, :o4, 1414285200
- tz.transition 2015, 3, :o7, 1427590800
- tz.transition 2015, 10, :o4, 1445734800
- tz.transition 2016, 3, :o7, 1459040400
- tz.transition 2016, 10, :o4, 1477789200
- tz.transition 2017, 3, :o7, 1490490000
- tz.transition 2017, 10, :o4, 1509238800
- tz.transition 2018, 3, :o7, 1521939600
- tz.transition 2018, 10, :o4, 1540688400
- tz.transition 2019, 3, :o7, 1553994000
- tz.transition 2019, 10, :o4, 1572138000
- tz.transition 2020, 3, :o7, 1585443600
- tz.transition 2020, 10, :o4, 1603587600
- tz.transition 2021, 3, :o7, 1616893200
- tz.transition 2021, 10, :o4, 1635642000
- tz.transition 2022, 3, :o7, 1648342800
- tz.transition 2022, 10, :o4, 1667091600
- tz.transition 2023, 3, :o7, 1679792400
- tz.transition 2023, 10, :o4, 1698541200
- tz.transition 2024, 3, :o7, 1711846800
- tz.transition 2024, 10, :o4, 1729990800
- tz.transition 2025, 3, :o7, 1743296400
- tz.transition 2025, 10, :o4, 1761440400
- tz.transition 2026, 3, :o7, 1774746000
- tz.transition 2026, 10, :o4, 1792890000
- tz.transition 2027, 3, :o7, 1806195600
- tz.transition 2027, 10, :o4, 1824944400
- tz.transition 2028, 3, :o7, 1837645200
- tz.transition 2028, 10, :o4, 1856394000
- tz.transition 2029, 3, :o7, 1869094800
- tz.transition 2029, 10, :o4, 1887843600
- tz.transition 2030, 3, :o7, 1901149200
- tz.transition 2030, 10, :o4, 1919293200
- tz.transition 2031, 3, :o7, 1932598800
- tz.transition 2031, 10, :o4, 1950742800
- tz.transition 2032, 3, :o7, 1964048400
- tz.transition 2032, 10, :o4, 1982797200
- tz.transition 2033, 3, :o7, 1995498000
- tz.transition 2033, 10, :o4, 2014246800
- tz.transition 2034, 3, :o7, 2026947600
- tz.transition 2034, 10, :o4, 2045696400
- tz.transition 2035, 3, :o7, 2058397200
- tz.transition 2035, 10, :o4, 2077146000
- tz.transition 2036, 3, :o7, 2090451600
- tz.transition 2036, 10, :o4, 2108595600
- tz.transition 2037, 3, :o7, 2121901200
- tz.transition 2037, 10, :o4, 2140045200
- tz.transition 2038, 3, :o7, 59172253, 24
- tz.transition 2038, 10, :o4, 59177461, 24
- tz.transition 2039, 3, :o7, 59180989, 24
- tz.transition 2039, 10, :o4, 59186197, 24
- tz.transition 2040, 3, :o7, 59189725, 24
- tz.transition 2040, 10, :o4, 59194933, 24
- tz.transition 2041, 3, :o7, 59198629, 24
- tz.transition 2041, 10, :o4, 59203669, 24
- tz.transition 2042, 3, :o7, 59207365, 24
- tz.transition 2042, 10, :o4, 59212405, 24
- tz.transition 2043, 3, :o7, 59216101, 24
- tz.transition 2043, 10, :o4, 59221141, 24
- tz.transition 2044, 3, :o7, 59224837, 24
- tz.transition 2044, 10, :o4, 59230045, 24
- tz.transition 2045, 3, :o7, 59233573, 24
- tz.transition 2045, 10, :o4, 59238781, 24
- tz.transition 2046, 3, :o7, 59242309, 24
- tz.transition 2046, 10, :o4, 59247517, 24
- tz.transition 2047, 3, :o7, 59251213, 24
- tz.transition 2047, 10, :o4, 59256253, 24
- tz.transition 2048, 3, :o7, 59259949, 24
- tz.transition 2048, 10, :o4, 59264989, 24
- tz.transition 2049, 3, :o7, 59268685, 24
- tz.transition 2049, 10, :o4, 59273893, 24
- tz.transition 2050, 3, :o7, 59277421, 24
- tz.transition 2050, 10, :o4, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Vienna.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Vienna.rb
deleted file mode 100644
index 990aabab66..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Vienna.rb
+++ /dev/null
@@ -1,183 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Vienna
- include TimezoneDefinition
-
- timezone 'Europe/Vienna' do |tz|
- tz.offset :o0, 3920, 0, :LMT
- tz.offset :o1, 3600, 0, :CET
- tz.offset :o2, 3600, 3600, :CEST
-
- tz.transition 1893, 3, :o1, 2605558811, 1080
- tz.transition 1916, 4, :o2, 29051813, 12
- tz.transition 1916, 9, :o1, 58107299, 24
- tz.transition 1917, 4, :o2, 58112029, 24
- tz.transition 1917, 9, :o1, 58115725, 24
- tz.transition 1918, 4, :o2, 58120765, 24
- tz.transition 1918, 9, :o1, 58124461, 24
- tz.transition 1920, 4, :o2, 58138069, 24
- tz.transition 1920, 9, :o1, 58141933, 24
- tz.transition 1940, 4, :o2, 58313293, 24
- tz.transition 1942, 11, :o1, 58335973, 24
- tz.transition 1943, 3, :o2, 58339501, 24
- tz.transition 1943, 10, :o1, 58344037, 24
- tz.transition 1944, 4, :o2, 58348405, 24
- tz.transition 1944, 10, :o1, 58352773, 24
- tz.transition 1945, 4, :o2, 58357141, 24
- tz.transition 1945, 4, :o1, 58357381, 24
- tz.transition 1946, 4, :o2, 58366189, 24
- tz.transition 1946, 10, :o1, 58370389, 24
- tz.transition 1947, 4, :o2, 58374757, 24
- tz.transition 1947, 10, :o1, 58379125, 24
- tz.transition 1948, 4, :o2, 58383829, 24
- tz.transition 1948, 10, :o1, 58387861, 24
- tz.transition 1980, 4, :o2, 323823600
- tz.transition 1980, 9, :o1, 338940000
- tz.transition 1981, 3, :o2, 354675600
- tz.transition 1981, 9, :o1, 370400400
- tz.transition 1982, 3, :o2, 386125200
- tz.transition 1982, 9, :o1, 401850000
- tz.transition 1983, 3, :o2, 417574800
- tz.transition 1983, 9, :o1, 433299600
- tz.transition 1984, 3, :o2, 449024400
- tz.transition 1984, 9, :o1, 465354000
- tz.transition 1985, 3, :o2, 481078800
- tz.transition 1985, 9, :o1, 496803600
- tz.transition 1986, 3, :o2, 512528400
- tz.transition 1986, 9, :o1, 528253200
- tz.transition 1987, 3, :o2, 543978000
- tz.transition 1987, 9, :o1, 559702800
- tz.transition 1988, 3, :o2, 575427600
- tz.transition 1988, 9, :o1, 591152400
- tz.transition 1989, 3, :o2, 606877200
- tz.transition 1989, 9, :o1, 622602000
- tz.transition 1990, 3, :o2, 638326800
- tz.transition 1990, 9, :o1, 654656400
- tz.transition 1991, 3, :o2, 670381200
- tz.transition 1991, 9, :o1, 686106000
- tz.transition 1992, 3, :o2, 701830800
- tz.transition 1992, 9, :o1, 717555600
- tz.transition 1993, 3, :o2, 733280400
- tz.transition 1993, 9, :o1, 749005200
- tz.transition 1994, 3, :o2, 764730000
- tz.transition 1994, 9, :o1, 780454800
- tz.transition 1995, 3, :o2, 796179600
- tz.transition 1995, 9, :o1, 811904400
- tz.transition 1996, 3, :o2, 828234000
- tz.transition 1996, 10, :o1, 846378000
- tz.transition 1997, 3, :o2, 859683600
- tz.transition 1997, 10, :o1, 877827600
- tz.transition 1998, 3, :o2, 891133200
- tz.transition 1998, 10, :o1, 909277200
- tz.transition 1999, 3, :o2, 922582800
- tz.transition 1999, 10, :o1, 941331600
- tz.transition 2000, 3, :o2, 954032400
- tz.transition 2000, 10, :o1, 972781200
- tz.transition 2001, 3, :o2, 985482000
- tz.transition 2001, 10, :o1, 1004230800
- tz.transition 2002, 3, :o2, 1017536400
- tz.transition 2002, 10, :o1, 1035680400
- tz.transition 2003, 3, :o2, 1048986000
- tz.transition 2003, 10, :o1, 1067130000
- tz.transition 2004, 3, :o2, 1080435600
- tz.transition 2004, 10, :o1, 1099184400
- tz.transition 2005, 3, :o2, 1111885200
- tz.transition 2005, 10, :o1, 1130634000
- tz.transition 2006, 3, :o2, 1143334800
- tz.transition 2006, 10, :o1, 1162083600
- tz.transition 2007, 3, :o2, 1174784400
- tz.transition 2007, 10, :o1, 1193533200
- tz.transition 2008, 3, :o2, 1206838800
- tz.transition 2008, 10, :o1, 1224982800
- tz.transition 2009, 3, :o2, 1238288400
- tz.transition 2009, 10, :o1, 1256432400
- tz.transition 2010, 3, :o2, 1269738000
- tz.transition 2010, 10, :o1, 1288486800
- tz.transition 2011, 3, :o2, 1301187600
- tz.transition 2011, 10, :o1, 1319936400
- tz.transition 2012, 3, :o2, 1332637200
- tz.transition 2012, 10, :o1, 1351386000
- tz.transition 2013, 3, :o2, 1364691600
- tz.transition 2013, 10, :o1, 1382835600
- tz.transition 2014, 3, :o2, 1396141200
- tz.transition 2014, 10, :o1, 1414285200
- tz.transition 2015, 3, :o2, 1427590800
- tz.transition 2015, 10, :o1, 1445734800
- tz.transition 2016, 3, :o2, 1459040400
- tz.transition 2016, 10, :o1, 1477789200
- tz.transition 2017, 3, :o2, 1490490000
- tz.transition 2017, 10, :o1, 1509238800
- tz.transition 2018, 3, :o2, 1521939600
- tz.transition 2018, 10, :o1, 1540688400
- tz.transition 2019, 3, :o2, 1553994000
- tz.transition 2019, 10, :o1, 1572138000
- tz.transition 2020, 3, :o2, 1585443600
- tz.transition 2020, 10, :o1, 1603587600
- tz.transition 2021, 3, :o2, 1616893200
- tz.transition 2021, 10, :o1, 1635642000
- tz.transition 2022, 3, :o2, 1648342800
- tz.transition 2022, 10, :o1, 1667091600
- tz.transition 2023, 3, :o2, 1679792400
- tz.transition 2023, 10, :o1, 1698541200
- tz.transition 2024, 3, :o2, 1711846800
- tz.transition 2024, 10, :o1, 1729990800
- tz.transition 2025, 3, :o2, 1743296400
- tz.transition 2025, 10, :o1, 1761440400
- tz.transition 2026, 3, :o2, 1774746000
- tz.transition 2026, 10, :o1, 1792890000
- tz.transition 2027, 3, :o2, 1806195600
- tz.transition 2027, 10, :o1, 1824944400
- tz.transition 2028, 3, :o2, 1837645200
- tz.transition 2028, 10, :o1, 1856394000
- tz.transition 2029, 3, :o2, 1869094800
- tz.transition 2029, 10, :o1, 1887843600
- tz.transition 2030, 3, :o2, 1901149200
- tz.transition 2030, 10, :o1, 1919293200
- tz.transition 2031, 3, :o2, 1932598800
- tz.transition 2031, 10, :o1, 1950742800
- tz.transition 2032, 3, :o2, 1964048400
- tz.transition 2032, 10, :o1, 1982797200
- tz.transition 2033, 3, :o2, 1995498000
- tz.transition 2033, 10, :o1, 2014246800
- tz.transition 2034, 3, :o2, 2026947600
- tz.transition 2034, 10, :o1, 2045696400
- tz.transition 2035, 3, :o2, 2058397200
- tz.transition 2035, 10, :o1, 2077146000
- tz.transition 2036, 3, :o2, 2090451600
- tz.transition 2036, 10, :o1, 2108595600
- tz.transition 2037, 3, :o2, 2121901200
- tz.transition 2037, 10, :o1, 2140045200
- tz.transition 2038, 3, :o2, 59172253, 24
- tz.transition 2038, 10, :o1, 59177461, 24
- tz.transition 2039, 3, :o2, 59180989, 24
- tz.transition 2039, 10, :o1, 59186197, 24
- tz.transition 2040, 3, :o2, 59189725, 24
- tz.transition 2040, 10, :o1, 59194933, 24
- tz.transition 2041, 3, :o2, 59198629, 24
- tz.transition 2041, 10, :o1, 59203669, 24
- tz.transition 2042, 3, :o2, 59207365, 24
- tz.transition 2042, 10, :o1, 59212405, 24
- tz.transition 2043, 3, :o2, 59216101, 24
- tz.transition 2043, 10, :o1, 59221141, 24
- tz.transition 2044, 3, :o2, 59224837, 24
- tz.transition 2044, 10, :o1, 59230045, 24
- tz.transition 2045, 3, :o2, 59233573, 24
- tz.transition 2045, 10, :o1, 59238781, 24
- tz.transition 2046, 3, :o2, 59242309, 24
- tz.transition 2046, 10, :o1, 59247517, 24
- tz.transition 2047, 3, :o2, 59251213, 24
- tz.transition 2047, 10, :o1, 59256253, 24
- tz.transition 2048, 3, :o2, 59259949, 24
- tz.transition 2048, 10, :o1, 59264989, 24
- tz.transition 2049, 3, :o2, 59268685, 24
- tz.transition 2049, 10, :o1, 59273893, 24
- tz.transition 2050, 3, :o2, 59277421, 24
- tz.transition 2050, 10, :o1, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Vilnius.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Vilnius.rb
deleted file mode 100644
index d89d095a75..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Vilnius.rb
+++ /dev/null
@@ -1,170 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Vilnius
- include TimezoneDefinition
-
- timezone 'Europe/Vilnius' do |tz|
- tz.offset :o0, 6076, 0, :LMT
- tz.offset :o1, 5040, 0, :WMT
- tz.offset :o2, 5736, 0, :KMT
- tz.offset :o3, 3600, 0, :CET
- tz.offset :o4, 7200, 0, :EET
- tz.offset :o5, 10800, 0, :MSK
- tz.offset :o6, 3600, 3600, :CEST
- tz.offset :o7, 10800, 3600, :MSD
- tz.offset :o8, 7200, 3600, :EEST
-
- tz.transition 1879, 12, :o1, 52006653281, 21600
- tz.transition 1916, 12, :o2, 290547533, 120
- tz.transition 1919, 10, :o3, 8720069161, 3600
- tz.transition 1920, 7, :o4, 58140419, 24
- tz.transition 1920, 10, :o3, 29071277, 12
- tz.transition 1940, 8, :o5, 58316267, 24
- tz.transition 1941, 6, :o6, 19441355, 8
- tz.transition 1942, 11, :o3, 58335973, 24
- tz.transition 1943, 3, :o6, 58339501, 24
- tz.transition 1943, 10, :o3, 58344037, 24
- tz.transition 1944, 4, :o6, 58348405, 24
- tz.transition 1944, 7, :o5, 29175641, 12
- tz.transition 1981, 3, :o7, 354920400
- tz.transition 1981, 9, :o5, 370728000
- tz.transition 1982, 3, :o7, 386456400
- tz.transition 1982, 9, :o5, 402264000
- tz.transition 1983, 3, :o7, 417992400
- tz.transition 1983, 9, :o5, 433800000
- tz.transition 1984, 3, :o7, 449614800
- tz.transition 1984, 9, :o5, 465346800
- tz.transition 1985, 3, :o7, 481071600
- tz.transition 1985, 9, :o5, 496796400
- tz.transition 1986, 3, :o7, 512521200
- tz.transition 1986, 9, :o5, 528246000
- tz.transition 1987, 3, :o7, 543970800
- tz.transition 1987, 9, :o5, 559695600
- tz.transition 1988, 3, :o7, 575420400
- tz.transition 1988, 9, :o5, 591145200
- tz.transition 1989, 3, :o7, 606870000
- tz.transition 1989, 9, :o5, 622594800
- tz.transition 1990, 3, :o7, 638319600
- tz.transition 1990, 9, :o5, 654649200
- tz.transition 1991, 3, :o8, 670374000
- tz.transition 1991, 9, :o4, 686102400
- tz.transition 1992, 3, :o8, 701827200
- tz.transition 1992, 9, :o4, 717552000
- tz.transition 1993, 3, :o8, 733276800
- tz.transition 1993, 9, :o4, 749001600
- tz.transition 1994, 3, :o8, 764726400
- tz.transition 1994, 9, :o4, 780451200
- tz.transition 1995, 3, :o8, 796176000
- tz.transition 1995, 9, :o4, 811900800
- tz.transition 1996, 3, :o8, 828230400
- tz.transition 1996, 10, :o4, 846374400
- tz.transition 1997, 3, :o8, 859680000
- tz.transition 1997, 10, :o4, 877824000
- tz.transition 1998, 3, :o6, 891133200
- tz.transition 1998, 10, :o3, 909277200
- tz.transition 1999, 3, :o6, 922582800
- tz.transition 1999, 10, :o4, 941331600
- tz.transition 2003, 3, :o8, 1048986000
- tz.transition 2003, 10, :o4, 1067130000
- tz.transition 2004, 3, :o8, 1080435600
- tz.transition 2004, 10, :o4, 1099184400
- tz.transition 2005, 3, :o8, 1111885200
- tz.transition 2005, 10, :o4, 1130634000
- tz.transition 2006, 3, :o8, 1143334800
- tz.transition 2006, 10, :o4, 1162083600
- tz.transition 2007, 3, :o8, 1174784400
- tz.transition 2007, 10, :o4, 1193533200
- tz.transition 2008, 3, :o8, 1206838800
- tz.transition 2008, 10, :o4, 1224982800
- tz.transition 2009, 3, :o8, 1238288400
- tz.transition 2009, 10, :o4, 1256432400
- tz.transition 2010, 3, :o8, 1269738000
- tz.transition 2010, 10, :o4, 1288486800
- tz.transition 2011, 3, :o8, 1301187600
- tz.transition 2011, 10, :o4, 1319936400
- tz.transition 2012, 3, :o8, 1332637200
- tz.transition 2012, 10, :o4, 1351386000
- tz.transition 2013, 3, :o8, 1364691600
- tz.transition 2013, 10, :o4, 1382835600
- tz.transition 2014, 3, :o8, 1396141200
- tz.transition 2014, 10, :o4, 1414285200
- tz.transition 2015, 3, :o8, 1427590800
- tz.transition 2015, 10, :o4, 1445734800
- tz.transition 2016, 3, :o8, 1459040400
- tz.transition 2016, 10, :o4, 1477789200
- tz.transition 2017, 3, :o8, 1490490000
- tz.transition 2017, 10, :o4, 1509238800
- tz.transition 2018, 3, :o8, 1521939600
- tz.transition 2018, 10, :o4, 1540688400
- tz.transition 2019, 3, :o8, 1553994000
- tz.transition 2019, 10, :o4, 1572138000
- tz.transition 2020, 3, :o8, 1585443600
- tz.transition 2020, 10, :o4, 1603587600
- tz.transition 2021, 3, :o8, 1616893200
- tz.transition 2021, 10, :o4, 1635642000
- tz.transition 2022, 3, :o8, 1648342800
- tz.transition 2022, 10, :o4, 1667091600
- tz.transition 2023, 3, :o8, 1679792400
- tz.transition 2023, 10, :o4, 1698541200
- tz.transition 2024, 3, :o8, 1711846800
- tz.transition 2024, 10, :o4, 1729990800
- tz.transition 2025, 3, :o8, 1743296400
- tz.transition 2025, 10, :o4, 1761440400
- tz.transition 2026, 3, :o8, 1774746000
- tz.transition 2026, 10, :o4, 1792890000
- tz.transition 2027, 3, :o8, 1806195600
- tz.transition 2027, 10, :o4, 1824944400
- tz.transition 2028, 3, :o8, 1837645200
- tz.transition 2028, 10, :o4, 1856394000
- tz.transition 2029, 3, :o8, 1869094800
- tz.transition 2029, 10, :o4, 1887843600
- tz.transition 2030, 3, :o8, 1901149200
- tz.transition 2030, 10, :o4, 1919293200
- tz.transition 2031, 3, :o8, 1932598800
- tz.transition 2031, 10, :o4, 1950742800
- tz.transition 2032, 3, :o8, 1964048400
- tz.transition 2032, 10, :o4, 1982797200
- tz.transition 2033, 3, :o8, 1995498000
- tz.transition 2033, 10, :o4, 2014246800
- tz.transition 2034, 3, :o8, 2026947600
- tz.transition 2034, 10, :o4, 2045696400
- tz.transition 2035, 3, :o8, 2058397200
- tz.transition 2035, 10, :o4, 2077146000
- tz.transition 2036, 3, :o8, 2090451600
- tz.transition 2036, 10, :o4, 2108595600
- tz.transition 2037, 3, :o8, 2121901200
- tz.transition 2037, 10, :o4, 2140045200
- tz.transition 2038, 3, :o8, 59172253, 24
- tz.transition 2038, 10, :o4, 59177461, 24
- tz.transition 2039, 3, :o8, 59180989, 24
- tz.transition 2039, 10, :o4, 59186197, 24
- tz.transition 2040, 3, :o8, 59189725, 24
- tz.transition 2040, 10, :o4, 59194933, 24
- tz.transition 2041, 3, :o8, 59198629, 24
- tz.transition 2041, 10, :o4, 59203669, 24
- tz.transition 2042, 3, :o8, 59207365, 24
- tz.transition 2042, 10, :o4, 59212405, 24
- tz.transition 2043, 3, :o8, 59216101, 24
- tz.transition 2043, 10, :o4, 59221141, 24
- tz.transition 2044, 3, :o8, 59224837, 24
- tz.transition 2044, 10, :o4, 59230045, 24
- tz.transition 2045, 3, :o8, 59233573, 24
- tz.transition 2045, 10, :o4, 59238781, 24
- tz.transition 2046, 3, :o8, 59242309, 24
- tz.transition 2046, 10, :o4, 59247517, 24
- tz.transition 2047, 3, :o8, 59251213, 24
- tz.transition 2047, 10, :o4, 59256253, 24
- tz.transition 2048, 3, :o8, 59259949, 24
- tz.transition 2048, 10, :o4, 59264989, 24
- tz.transition 2049, 3, :o8, 59268685, 24
- tz.transition 2049, 10, :o4, 59273893, 24
- tz.transition 2050, 3, :o8, 59277421, 24
- tz.transition 2050, 10, :o4, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Warsaw.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Warsaw.rb
deleted file mode 100644
index 7fa51c2691..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Warsaw.rb
+++ /dev/null
@@ -1,212 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Warsaw
- include TimezoneDefinition
-
- timezone 'Europe/Warsaw' do |tz|
- tz.offset :o0, 5040, 0, :LMT
- tz.offset :o1, 5040, 0, :WMT
- tz.offset :o2, 3600, 0, :CET
- tz.offset :o3, 3600, 3600, :CEST
- tz.offset :o4, 7200, 0, :EET
- tz.offset :o5, 7200, 3600, :EEST
-
- tz.transition 1879, 12, :o1, 288925853, 120
- tz.transition 1915, 8, :o2, 290485733, 120
- tz.transition 1916, 4, :o3, 29051813, 12
- tz.transition 1916, 9, :o2, 58107299, 24
- tz.transition 1917, 4, :o3, 58112029, 24
- tz.transition 1917, 9, :o2, 58115725, 24
- tz.transition 1918, 4, :o3, 58120765, 24
- tz.transition 1918, 9, :o4, 58124461, 24
- tz.transition 1919, 4, :o5, 4844127, 2
- tz.transition 1919, 9, :o4, 4844435, 2
- tz.transition 1922, 5, :o2, 29078477, 12
- tz.transition 1940, 6, :o3, 58315285, 24
- tz.transition 1942, 11, :o2, 58335973, 24
- tz.transition 1943, 3, :o3, 58339501, 24
- tz.transition 1943, 10, :o2, 58344037, 24
- tz.transition 1944, 4, :o3, 58348405, 24
- tz.transition 1944, 10, :o2, 4862735, 2
- tz.transition 1945, 4, :o3, 58357787, 24
- tz.transition 1945, 10, :o2, 29181125, 12
- tz.transition 1946, 4, :o3, 58366187, 24
- tz.transition 1946, 10, :o2, 58370413, 24
- tz.transition 1947, 5, :o3, 58375429, 24
- tz.transition 1947, 10, :o2, 58379125, 24
- tz.transition 1948, 4, :o3, 58383829, 24
- tz.transition 1948, 10, :o2, 58387861, 24
- tz.transition 1949, 4, :o3, 58392397, 24
- tz.transition 1949, 10, :o2, 58396597, 24
- tz.transition 1957, 6, :o3, 4871983, 2
- tz.transition 1957, 9, :o2, 4872221, 2
- tz.transition 1958, 3, :o3, 4872585, 2
- tz.transition 1958, 9, :o2, 4872949, 2
- tz.transition 1959, 5, :o3, 4873439, 2
- tz.transition 1959, 10, :o2, 4873691, 2
- tz.transition 1960, 4, :o3, 4874055, 2
- tz.transition 1960, 10, :o2, 4874419, 2
- tz.transition 1961, 5, :o3, 4874895, 2
- tz.transition 1961, 10, :o2, 4875147, 2
- tz.transition 1962, 5, :o3, 4875623, 2
- tz.transition 1962, 9, :o2, 4875875, 2
- tz.transition 1963, 5, :o3, 4876351, 2
- tz.transition 1963, 9, :o2, 4876603, 2
- tz.transition 1964, 5, :o3, 4877093, 2
- tz.transition 1964, 9, :o2, 4877331, 2
- tz.transition 1977, 4, :o3, 228873600
- tz.transition 1977, 9, :o2, 243993600
- tz.transition 1978, 4, :o3, 260323200
- tz.transition 1978, 10, :o2, 276048000
- tz.transition 1979, 4, :o3, 291772800
- tz.transition 1979, 9, :o2, 307497600
- tz.transition 1980, 4, :o3, 323827200
- tz.transition 1980, 9, :o2, 338947200
- tz.transition 1981, 3, :o3, 354672000
- tz.transition 1981, 9, :o2, 370396800
- tz.transition 1982, 3, :o3, 386121600
- tz.transition 1982, 9, :o2, 401846400
- tz.transition 1983, 3, :o3, 417571200
- tz.transition 1983, 9, :o2, 433296000
- tz.transition 1984, 3, :o3, 449020800
- tz.transition 1984, 9, :o2, 465350400
- tz.transition 1985, 3, :o3, 481075200
- tz.transition 1985, 9, :o2, 496800000
- tz.transition 1986, 3, :o3, 512524800
- tz.transition 1986, 9, :o2, 528249600
- tz.transition 1987, 3, :o3, 543974400
- tz.transition 1987, 9, :o2, 559699200
- tz.transition 1988, 3, :o3, 575427600
- tz.transition 1988, 9, :o2, 591152400
- tz.transition 1989, 3, :o3, 606877200
- tz.transition 1989, 9, :o2, 622602000
- tz.transition 1990, 3, :o3, 638326800
- tz.transition 1990, 9, :o2, 654656400
- tz.transition 1991, 3, :o3, 670381200
- tz.transition 1991, 9, :o2, 686106000
- tz.transition 1992, 3, :o3, 701830800
- tz.transition 1992, 9, :o2, 717555600
- tz.transition 1993, 3, :o3, 733280400
- tz.transition 1993, 9, :o2, 749005200
- tz.transition 1994, 3, :o3, 764730000
- tz.transition 1994, 9, :o2, 780454800
- tz.transition 1995, 3, :o3, 796179600
- tz.transition 1995, 9, :o2, 811904400
- tz.transition 1996, 3, :o3, 828234000
- tz.transition 1996, 10, :o2, 846378000
- tz.transition 1997, 3, :o3, 859683600
- tz.transition 1997, 10, :o2, 877827600
- tz.transition 1998, 3, :o3, 891133200
- tz.transition 1998, 10, :o2, 909277200
- tz.transition 1999, 3, :o3, 922582800
- tz.transition 1999, 10, :o2, 941331600
- tz.transition 2000, 3, :o3, 954032400
- tz.transition 2000, 10, :o2, 972781200
- tz.transition 2001, 3, :o3, 985482000
- tz.transition 2001, 10, :o2, 1004230800
- tz.transition 2002, 3, :o3, 1017536400
- tz.transition 2002, 10, :o2, 1035680400
- tz.transition 2003, 3, :o3, 1048986000
- tz.transition 2003, 10, :o2, 1067130000
- tz.transition 2004, 3, :o3, 1080435600
- tz.transition 2004, 10, :o2, 1099184400
- tz.transition 2005, 3, :o3, 1111885200
- tz.transition 2005, 10, :o2, 1130634000
- tz.transition 2006, 3, :o3, 1143334800
- tz.transition 2006, 10, :o2, 1162083600
- tz.transition 2007, 3, :o3, 1174784400
- tz.transition 2007, 10, :o2, 1193533200
- tz.transition 2008, 3, :o3, 1206838800
- tz.transition 2008, 10, :o2, 1224982800
- tz.transition 2009, 3, :o3, 1238288400
- tz.transition 2009, 10, :o2, 1256432400
- tz.transition 2010, 3, :o3, 1269738000
- tz.transition 2010, 10, :o2, 1288486800
- tz.transition 2011, 3, :o3, 1301187600
- tz.transition 2011, 10, :o2, 1319936400
- tz.transition 2012, 3, :o3, 1332637200
- tz.transition 2012, 10, :o2, 1351386000
- tz.transition 2013, 3, :o3, 1364691600
- tz.transition 2013, 10, :o2, 1382835600
- tz.transition 2014, 3, :o3, 1396141200
- tz.transition 2014, 10, :o2, 1414285200
- tz.transition 2015, 3, :o3, 1427590800
- tz.transition 2015, 10, :o2, 1445734800
- tz.transition 2016, 3, :o3, 1459040400
- tz.transition 2016, 10, :o2, 1477789200
- tz.transition 2017, 3, :o3, 1490490000
- tz.transition 2017, 10, :o2, 1509238800
- tz.transition 2018, 3, :o3, 1521939600
- tz.transition 2018, 10, :o2, 1540688400
- tz.transition 2019, 3, :o3, 1553994000
- tz.transition 2019, 10, :o2, 1572138000
- tz.transition 2020, 3, :o3, 1585443600
- tz.transition 2020, 10, :o2, 1603587600
- tz.transition 2021, 3, :o3, 1616893200
- tz.transition 2021, 10, :o2, 1635642000
- tz.transition 2022, 3, :o3, 1648342800
- tz.transition 2022, 10, :o2, 1667091600
- tz.transition 2023, 3, :o3, 1679792400
- tz.transition 2023, 10, :o2, 1698541200
- tz.transition 2024, 3, :o3, 1711846800
- tz.transition 2024, 10, :o2, 1729990800
- tz.transition 2025, 3, :o3, 1743296400
- tz.transition 2025, 10, :o2, 1761440400
- tz.transition 2026, 3, :o3, 1774746000
- tz.transition 2026, 10, :o2, 1792890000
- tz.transition 2027, 3, :o3, 1806195600
- tz.transition 2027, 10, :o2, 1824944400
- tz.transition 2028, 3, :o3, 1837645200
- tz.transition 2028, 10, :o2, 1856394000
- tz.transition 2029, 3, :o3, 1869094800
- tz.transition 2029, 10, :o2, 1887843600
- tz.transition 2030, 3, :o3, 1901149200
- tz.transition 2030, 10, :o2, 1919293200
- tz.transition 2031, 3, :o3, 1932598800
- tz.transition 2031, 10, :o2, 1950742800
- tz.transition 2032, 3, :o3, 1964048400
- tz.transition 2032, 10, :o2, 1982797200
- tz.transition 2033, 3, :o3, 1995498000
- tz.transition 2033, 10, :o2, 2014246800
- tz.transition 2034, 3, :o3, 2026947600
- tz.transition 2034, 10, :o2, 2045696400
- tz.transition 2035, 3, :o3, 2058397200
- tz.transition 2035, 10, :o2, 2077146000
- tz.transition 2036, 3, :o3, 2090451600
- tz.transition 2036, 10, :o2, 2108595600
- tz.transition 2037, 3, :o3, 2121901200
- tz.transition 2037, 10, :o2, 2140045200
- tz.transition 2038, 3, :o3, 59172253, 24
- tz.transition 2038, 10, :o2, 59177461, 24
- tz.transition 2039, 3, :o3, 59180989, 24
- tz.transition 2039, 10, :o2, 59186197, 24
- tz.transition 2040, 3, :o3, 59189725, 24
- tz.transition 2040, 10, :o2, 59194933, 24
- tz.transition 2041, 3, :o3, 59198629, 24
- tz.transition 2041, 10, :o2, 59203669, 24
- tz.transition 2042, 3, :o3, 59207365, 24
- tz.transition 2042, 10, :o2, 59212405, 24
- tz.transition 2043, 3, :o3, 59216101, 24
- tz.transition 2043, 10, :o2, 59221141, 24
- tz.transition 2044, 3, :o3, 59224837, 24
- tz.transition 2044, 10, :o2, 59230045, 24
- tz.transition 2045, 3, :o3, 59233573, 24
- tz.transition 2045, 10, :o2, 59238781, 24
- tz.transition 2046, 3, :o3, 59242309, 24
- tz.transition 2046, 10, :o2, 59247517, 24
- tz.transition 2047, 3, :o3, 59251213, 24
- tz.transition 2047, 10, :o2, 59256253, 24
- tz.transition 2048, 3, :o3, 59259949, 24
- tz.transition 2048, 10, :o2, 59264989, 24
- tz.transition 2049, 3, :o3, 59268685, 24
- tz.transition 2049, 10, :o2, 59273893, 24
- tz.transition 2050, 3, :o3, 59277421, 24
- tz.transition 2050, 10, :o2, 59282629, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Zagreb.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Zagreb.rb
deleted file mode 100644
index ecdd903d28..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Europe/Zagreb.rb
+++ /dev/null
@@ -1,13 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Europe
- module Zagreb
- include TimezoneDefinition
-
- linked_timezone 'Europe/Zagreb', 'Europe/Belgrade'
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Auckland.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Auckland.rb
deleted file mode 100644
index a524fd6b6b..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Auckland.rb
+++ /dev/null
@@ -1,202 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Pacific
- module Auckland
- include TimezoneDefinition
-
- timezone 'Pacific/Auckland' do |tz|
- tz.offset :o0, 41944, 0, :LMT
- tz.offset :o1, 41400, 0, :NZMT
- tz.offset :o2, 41400, 3600, :NZST
- tz.offset :o3, 41400, 1800, :NZST
- tz.offset :o4, 43200, 0, :NZST
- tz.offset :o5, 43200, 3600, :NZDT
-
- tz.transition 1868, 11, :o1, 25959290557, 10800
- tz.transition 1927, 11, :o2, 116409125, 48
- tz.transition 1928, 3, :o1, 38804945, 16
- tz.transition 1928, 10, :o3, 116425589, 48
- tz.transition 1929, 3, :o1, 29108245, 12
- tz.transition 1929, 10, :o3, 116443061, 48
- tz.transition 1930, 3, :o1, 29112613, 12
- tz.transition 1930, 10, :o3, 116460533, 48
- tz.transition 1931, 3, :o1, 29116981, 12
- tz.transition 1931, 10, :o3, 116478005, 48
- tz.transition 1932, 3, :o1, 29121433, 12
- tz.transition 1932, 10, :o3, 116495477, 48
- tz.transition 1933, 3, :o1, 29125801, 12
- tz.transition 1933, 10, :o3, 116512949, 48
- tz.transition 1934, 4, :o1, 29130673, 12
- tz.transition 1934, 9, :o3, 116530085, 48
- tz.transition 1935, 4, :o1, 29135041, 12
- tz.transition 1935, 9, :o3, 116547557, 48
- tz.transition 1936, 4, :o1, 29139409, 12
- tz.transition 1936, 9, :o3, 116565029, 48
- tz.transition 1937, 4, :o1, 29143777, 12
- tz.transition 1937, 9, :o3, 116582501, 48
- tz.transition 1938, 4, :o1, 29148145, 12
- tz.transition 1938, 9, :o3, 116599973, 48
- tz.transition 1939, 4, :o1, 29152597, 12
- tz.transition 1939, 9, :o3, 116617445, 48
- tz.transition 1940, 4, :o1, 29156965, 12
- tz.transition 1940, 9, :o3, 116635253, 48
- tz.transition 1945, 12, :o4, 2431821, 1
- tz.transition 1974, 11, :o5, 152632800
- tz.transition 1975, 2, :o4, 162309600
- tz.transition 1975, 10, :o5, 183477600
- tz.transition 1976, 3, :o4, 194968800
- tz.transition 1976, 10, :o5, 215532000
- tz.transition 1977, 3, :o4, 226418400
- tz.transition 1977, 10, :o5, 246981600
- tz.transition 1978, 3, :o4, 257868000
- tz.transition 1978, 10, :o5, 278431200
- tz.transition 1979, 3, :o4, 289317600
- tz.transition 1979, 10, :o5, 309880800
- tz.transition 1980, 3, :o4, 320767200
- tz.transition 1980, 10, :o5, 341330400
- tz.transition 1981, 2, :o4, 352216800
- tz.transition 1981, 10, :o5, 372780000
- tz.transition 1982, 3, :o4, 384271200
- tz.transition 1982, 10, :o5, 404834400
- tz.transition 1983, 3, :o4, 415720800
- tz.transition 1983, 10, :o5, 436284000
- tz.transition 1984, 3, :o4, 447170400
- tz.transition 1984, 10, :o5, 467733600
- tz.transition 1985, 3, :o4, 478620000
- tz.transition 1985, 10, :o5, 499183200
- tz.transition 1986, 3, :o4, 510069600
- tz.transition 1986, 10, :o5, 530632800
- tz.transition 1987, 2, :o4, 541519200
- tz.transition 1987, 10, :o5, 562082400
- tz.transition 1988, 3, :o4, 573573600
- tz.transition 1988, 10, :o5, 594136800
- tz.transition 1989, 3, :o4, 605023200
- tz.transition 1989, 10, :o5, 623772000
- tz.transition 1990, 3, :o4, 637682400
- tz.transition 1990, 10, :o5, 655221600
- tz.transition 1991, 3, :o4, 669132000
- tz.transition 1991, 10, :o5, 686671200
- tz.transition 1992, 3, :o4, 700581600
- tz.transition 1992, 10, :o5, 718120800
- tz.transition 1993, 3, :o4, 732636000
- tz.transition 1993, 10, :o5, 749570400
- tz.transition 1994, 3, :o4, 764085600
- tz.transition 1994, 10, :o5, 781020000
- tz.transition 1995, 3, :o4, 795535200
- tz.transition 1995, 9, :o5, 812469600
- tz.transition 1996, 3, :o4, 826984800
- tz.transition 1996, 10, :o5, 844524000
- tz.transition 1997, 3, :o4, 858434400
- tz.transition 1997, 10, :o5, 875973600
- tz.transition 1998, 3, :o4, 889884000
- tz.transition 1998, 10, :o5, 907423200
- tz.transition 1999, 3, :o4, 921938400
- tz.transition 1999, 10, :o5, 938872800
- tz.transition 2000, 3, :o4, 953388000
- tz.transition 2000, 9, :o5, 970322400
- tz.transition 2001, 3, :o4, 984837600
- tz.transition 2001, 10, :o5, 1002376800
- tz.transition 2002, 3, :o4, 1016287200
- tz.transition 2002, 10, :o5, 1033826400
- tz.transition 2003, 3, :o4, 1047736800
- tz.transition 2003, 10, :o5, 1065276000
- tz.transition 2004, 3, :o4, 1079791200
- tz.transition 2004, 10, :o5, 1096725600
- tz.transition 2005, 3, :o4, 1111240800
- tz.transition 2005, 10, :o5, 1128175200
- tz.transition 2006, 3, :o4, 1142690400
- tz.transition 2006, 9, :o5, 1159624800
- tz.transition 2007, 3, :o4, 1174140000
- tz.transition 2007, 9, :o5, 1191074400
- tz.transition 2008, 4, :o4, 1207404000
- tz.transition 2008, 9, :o5, 1222524000
- tz.transition 2009, 4, :o4, 1238853600
- tz.transition 2009, 9, :o5, 1253973600
- tz.transition 2010, 4, :o4, 1270303200
- tz.transition 2010, 9, :o5, 1285423200
- tz.transition 2011, 4, :o4, 1301752800
- tz.transition 2011, 9, :o5, 1316872800
- tz.transition 2012, 3, :o4, 1333202400
- tz.transition 2012, 9, :o5, 1348927200
- tz.transition 2013, 4, :o4, 1365256800
- tz.transition 2013, 9, :o5, 1380376800
- tz.transition 2014, 4, :o4, 1396706400
- tz.transition 2014, 9, :o5, 1411826400
- tz.transition 2015, 4, :o4, 1428156000
- tz.transition 2015, 9, :o5, 1443276000
- tz.transition 2016, 4, :o4, 1459605600
- tz.transition 2016, 9, :o5, 1474725600
- tz.transition 2017, 4, :o4, 1491055200
- tz.transition 2017, 9, :o5, 1506175200
- tz.transition 2018, 3, :o4, 1522504800
- tz.transition 2018, 9, :o5, 1538229600
- tz.transition 2019, 4, :o4, 1554559200
- tz.transition 2019, 9, :o5, 1569679200
- tz.transition 2020, 4, :o4, 1586008800
- tz.transition 2020, 9, :o5, 1601128800
- tz.transition 2021, 4, :o4, 1617458400
- tz.transition 2021, 9, :o5, 1632578400
- tz.transition 2022, 4, :o4, 1648908000
- tz.transition 2022, 9, :o5, 1664028000
- tz.transition 2023, 4, :o4, 1680357600
- tz.transition 2023, 9, :o5, 1695477600
- tz.transition 2024, 4, :o4, 1712412000
- tz.transition 2024, 9, :o5, 1727532000
- tz.transition 2025, 4, :o4, 1743861600
- tz.transition 2025, 9, :o5, 1758981600
- tz.transition 2026, 4, :o4, 1775311200
- tz.transition 2026, 9, :o5, 1790431200
- tz.transition 2027, 4, :o4, 1806760800
- tz.transition 2027, 9, :o5, 1821880800
- tz.transition 2028, 4, :o4, 1838210400
- tz.transition 2028, 9, :o5, 1853330400
- tz.transition 2029, 3, :o4, 1869660000
- tz.transition 2029, 9, :o5, 1885384800
- tz.transition 2030, 4, :o4, 1901714400
- tz.transition 2030, 9, :o5, 1916834400
- tz.transition 2031, 4, :o4, 1933164000
- tz.transition 2031, 9, :o5, 1948284000
- tz.transition 2032, 4, :o4, 1964613600
- tz.transition 2032, 9, :o5, 1979733600
- tz.transition 2033, 4, :o4, 1996063200
- tz.transition 2033, 9, :o5, 2011183200
- tz.transition 2034, 4, :o4, 2027512800
- tz.transition 2034, 9, :o5, 2042632800
- tz.transition 2035, 3, :o4, 2058962400
- tz.transition 2035, 9, :o5, 2074687200
- tz.transition 2036, 4, :o4, 2091016800
- tz.transition 2036, 9, :o5, 2106136800
- tz.transition 2037, 4, :o4, 2122466400
- tz.transition 2037, 9, :o5, 2137586400
- tz.transition 2038, 4, :o4, 29586205, 12
- tz.transition 2038, 9, :o5, 29588305, 12
- tz.transition 2039, 4, :o4, 29590573, 12
- tz.transition 2039, 9, :o5, 29592673, 12
- tz.transition 2040, 3, :o4, 29594941, 12
- tz.transition 2040, 9, :o5, 29597125, 12
- tz.transition 2041, 4, :o4, 29599393, 12
- tz.transition 2041, 9, :o5, 29601493, 12
- tz.transition 2042, 4, :o4, 29603761, 12
- tz.transition 2042, 9, :o5, 29605861, 12
- tz.transition 2043, 4, :o4, 29608129, 12
- tz.transition 2043, 9, :o5, 29610229, 12
- tz.transition 2044, 4, :o4, 29612497, 12
- tz.transition 2044, 9, :o5, 29614597, 12
- tz.transition 2045, 4, :o4, 29616865, 12
- tz.transition 2045, 9, :o5, 29618965, 12
- tz.transition 2046, 3, :o4, 29621233, 12
- tz.transition 2046, 9, :o5, 29623417, 12
- tz.transition 2047, 4, :o4, 29625685, 12
- tz.transition 2047, 9, :o5, 29627785, 12
- tz.transition 2048, 4, :o4, 29630053, 12
- tz.transition 2048, 9, :o5, 29632153, 12
- tz.transition 2049, 4, :o4, 29634421, 12
- tz.transition 2049, 9, :o5, 29636521, 12
- tz.transition 2050, 4, :o4, 29638789, 12
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Fiji.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Fiji.rb
deleted file mode 100644
index 5fe9bbd9a6..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Fiji.rb
+++ /dev/null
@@ -1,23 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Pacific
- module Fiji
- include TimezoneDefinition
-
- timezone 'Pacific/Fiji' do |tz|
- tz.offset :o0, 42820, 0, :LMT
- tz.offset :o1, 43200, 0, :FJT
- tz.offset :o2, 43200, 3600, :FJST
-
- tz.transition 1915, 10, :o1, 10457838739, 4320
- tz.transition 1998, 10, :o2, 909842400
- tz.transition 1999, 2, :o1, 920124000
- tz.transition 1999, 11, :o2, 941896800
- tz.transition 2000, 2, :o1, 951573600
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Guam.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Guam.rb
deleted file mode 100644
index d4c1a0a682..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Guam.rb
+++ /dev/null
@@ -1,22 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Pacific
- module Guam
- include TimezoneDefinition
-
- timezone 'Pacific/Guam' do |tz|
- tz.offset :o0, -51660, 0, :LMT
- tz.offset :o1, 34740, 0, :LMT
- tz.offset :o2, 36000, 0, :GST
- tz.offset :o3, 36000, 0, :ChST
-
- tz.transition 1844, 12, :o1, 1149567407, 480
- tz.transition 1900, 12, :o2, 1159384847, 480
- tz.transition 2000, 12, :o3, 977493600
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Honolulu.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Honolulu.rb
deleted file mode 100644
index 204b226537..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Honolulu.rb
+++ /dev/null
@@ -1,28 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Pacific
- module Honolulu
- include TimezoneDefinition
-
- timezone 'Pacific/Honolulu' do |tz|
- tz.offset :o0, -37886, 0, :LMT
- tz.offset :o1, -37800, 0, :HST
- tz.offset :o2, -37800, 3600, :HDT
- tz.offset :o3, -37800, 3600, :HWT
- tz.offset :o4, -37800, 3600, :HPT
- tz.offset :o5, -36000, 0, :HST
-
- tz.transition 1900, 1, :o1, 104328926143, 43200
- tz.transition 1933, 4, :o2, 116505265, 48
- tz.transition 1933, 5, :o1, 116506271, 48
- tz.transition 1942, 2, :o3, 116659201, 48
- tz.transition 1945, 8, :o4, 58360379, 24
- tz.transition 1945, 9, :o1, 116722991, 48
- tz.transition 1947, 6, :o5, 116752561, 48
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Majuro.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Majuro.rb
deleted file mode 100644
index 32adad92c1..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Majuro.rb
+++ /dev/null
@@ -1,20 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Pacific
- module Majuro
- include TimezoneDefinition
-
- timezone 'Pacific/Majuro' do |tz|
- tz.offset :o0, 41088, 0, :LMT
- tz.offset :o1, 39600, 0, :MHT
- tz.offset :o2, 43200, 0, :MHT
-
- tz.transition 1900, 12, :o1, 1086923261, 450
- tz.transition 1969, 9, :o2, 58571881, 24
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Midway.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Midway.rb
deleted file mode 100644
index 97784fcc10..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Midway.rb
+++ /dev/null
@@ -1,25 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Pacific
- module Midway
- include TimezoneDefinition
-
- timezone 'Pacific/Midway' do |tz|
- tz.offset :o0, -42568, 0, :LMT
- tz.offset :o1, -39600, 0, :NST
- tz.offset :o2, -39600, 3600, :NDT
- tz.offset :o3, -39600, 0, :BST
- tz.offset :o4, -39600, 0, :SST
-
- tz.transition 1901, 1, :o1, 26086168721, 10800
- tz.transition 1956, 6, :o2, 58455071, 24
- tz.transition 1956, 9, :o1, 29228627, 12
- tz.transition 1967, 4, :o3, 58549967, 24
- tz.transition 1983, 11, :o4, 439038000
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Noumea.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Noumea.rb
deleted file mode 100644
index 70173db8ab..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Noumea.rb
+++ /dev/null
@@ -1,25 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Pacific
- module Noumea
- include TimezoneDefinition
-
- timezone 'Pacific/Noumea' do |tz|
- tz.offset :o0, 39948, 0, :LMT
- tz.offset :o1, 39600, 0, :NCT
- tz.offset :o2, 39600, 3600, :NCST
-
- tz.transition 1912, 1, :o1, 17419781071, 7200
- tz.transition 1977, 12, :o2, 250002000
- tz.transition 1978, 2, :o1, 257342400
- tz.transition 1978, 12, :o2, 281451600
- tz.transition 1979, 2, :o1, 288878400
- tz.transition 1996, 11, :o2, 849366000
- tz.transition 1997, 3, :o1, 857228400
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Pago_Pago.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Pago_Pago.rb
deleted file mode 100644
index c8fcd7d527..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Pago_Pago.rb
+++ /dev/null
@@ -1,26 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Pacific
- module Pago_Pago
- include TimezoneDefinition
-
- timezone 'Pacific/Pago_Pago' do |tz|
- tz.offset :o0, 45432, 0, :LMT
- tz.offset :o1, -40968, 0, :LMT
- tz.offset :o2, -41400, 0, :SAMT
- tz.offset :o3, -39600, 0, :NST
- tz.offset :o4, -39600, 0, :BST
- tz.offset :o5, -39600, 0, :SST
-
- tz.transition 1879, 7, :o1, 2889041969, 1200
- tz.transition 1911, 1, :o2, 2902845569, 1200
- tz.transition 1950, 1, :o3, 116797583, 48
- tz.transition 1967, 4, :o4, 58549967, 24
- tz.transition 1983, 11, :o5, 439038000
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Port_Moresby.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Port_Moresby.rb
deleted file mode 100644
index f06cf6d54f..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Port_Moresby.rb
+++ /dev/null
@@ -1,20 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Pacific
- module Port_Moresby
- include TimezoneDefinition
-
- timezone 'Pacific/Port_Moresby' do |tz|
- tz.offset :o0, 35320, 0, :LMT
- tz.offset :o1, 35312, 0, :PMMT
- tz.offset :o2, 36000, 0, :PGT
-
- tz.transition 1879, 12, :o1, 5200664597, 2160
- tz.transition 1894, 12, :o2, 13031248093, 5400
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Tongatapu.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Tongatapu.rb
deleted file mode 100644
index 7578d92f38..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/definitions/Pacific/Tongatapu.rb
+++ /dev/null
@@ -1,27 +0,0 @@
-require 'tzinfo/timezone_definition'
-
-module TZInfo
- module Definitions
- module Pacific
- module Tongatapu
- include TimezoneDefinition
-
- timezone 'Pacific/Tongatapu' do |tz|
- tz.offset :o0, 44360, 0, :LMT
- tz.offset :o1, 44400, 0, :TOT
- tz.offset :o2, 46800, 0, :TOT
- tz.offset :o3, 46800, 3600, :TOST
-
- tz.transition 1900, 12, :o1, 5217231571, 2160
- tz.transition 1940, 12, :o2, 174959639, 72
- tz.transition 1999, 10, :o3, 939214800
- tz.transition 2000, 3, :o2, 953384400
- tz.transition 2000, 11, :o3, 973342800
- tz.transition 2001, 1, :o2, 980596800
- tz.transition 2001, 11, :o3, 1004792400
- tz.transition 2002, 1, :o2, 1012046400
- end
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/info_timezone.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/info_timezone.rb
deleted file mode 100644
index 001303c594..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/info_timezone.rb
+++ /dev/null
@@ -1,52 +0,0 @@
-#--
-# Copyright (c) 2006 Philip Ross
-#
-# Permission is hereby granted, free of charge, to any person obtaining a copy
-# of this software and associated documentation files (the "Software"), to deal
-# in the Software without restriction, including without limitation the rights
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-# copies of the Software, and to permit persons to whom the Software is
-# furnished to do so, subject to the following conditions:
-#
-# The above copyright notice and this permission notice shall be included in all
-# copies or substantial portions of the Software.
-#
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-# THE SOFTWARE.
-#++
-
-require 'tzinfo/timezone'
-
-module TZInfo
-
- # A Timezone based on a TimezoneInfo.
- class InfoTimezone < Timezone #:nodoc:
-
- # Constructs a new InfoTimezone with a TimezoneInfo instance.
- def self.new(info)
- tz = super()
- tz.send(:setup, info)
- tz
- end
-
- # The identifier of the timezone, e.g. "Europe/Paris".
- def identifier
- @info.identifier
- end
-
- protected
- # The TimezoneInfo for this Timezone.
- def info
- @info
- end
-
- def setup(info)
- @info = info
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/linked_timezone.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/linked_timezone.rb
deleted file mode 100644
index f8ec4fca87..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/linked_timezone.rb
+++ /dev/null
@@ -1,51 +0,0 @@
-#--
-# Copyright (c) 2006 Philip Ross
-#
-# Permission is hereby granted, free of charge, to any person obtaining a copy
-# of this software and associated documentation files (the "Software"), to deal
-# in the Software without restriction, including without limitation the rights
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-# copies of the Software, and to permit persons to whom the Software is
-# furnished to do so, subject to the following conditions:
-#
-# The above copyright notice and this permission notice shall be included in all
-# copies or substantial portions of the Software.
-#
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-# THE SOFTWARE.
-#++
-
-require 'tzinfo/info_timezone'
-
-module TZInfo
-
- class LinkedTimezone < InfoTimezone #:nodoc:
- # Returns the TimezonePeriod for the given UTC time. utc can either be
- # a DateTime, Time or integer timestamp (Time.to_i). Any timezone
- # information in utc is ignored (it is treated as a UTC time).
- #
- # If no TimezonePeriod could be found, PeriodNotFound is raised.
- def period_for_utc(utc)
- @linked_timezone.period_for_utc(utc)
- end
-
- # Returns the set of TimezonePeriod instances that are valid for the given
- # local time as an array. If you just want a single period, use
- # period_for_local instead and specify how abiguities should be resolved.
- # Raises PeriodNotFound if no periods are found for the given time.
- def periods_for_local(local)
- @linked_timezone.periods_for_local(local)
- end
-
- protected
- def setup(info)
- super(info)
- @linked_timezone = Timezone.get(info.link_to_identifier)
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/linked_timezone_info.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/linked_timezone_info.rb
deleted file mode 100644
index 8197ff3e81..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/linked_timezone_info.rb
+++ /dev/null
@@ -1,44 +0,0 @@
-#--
-# Copyright (c) 2006 Philip Ross
-#
-# Permission is hereby granted, free of charge, to any person obtaining a copy
-# of this software and associated documentation files (the "Software"), to deal
-# in the Software without restriction, including without limitation the rights
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-# copies of the Software, and to permit persons to whom the Software is
-# furnished to do so, subject to the following conditions:
-#
-# The above copyright notice and this permission notice shall be included in all
-# copies or substantial portions of the Software.
-#
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-# THE SOFTWARE.
-#++
-
-require 'tzinfo/timezone_info'
-
-module TZInfo
- # Represents a linked timezone defined in a data module.
- class LinkedTimezoneInfo < TimezoneInfo #:nodoc:
-
- # The zone that provides the data (that this zone is an alias for).
- attr_reader :link_to_identifier
-
- # Constructs a new TimezoneInfo with an identifier and the identifier
- # of the zone linked to.
- def initialize(identifier, link_to_identifier)
- super(identifier)
- @link_to_identifier = link_to_identifier
- end
-
- # Returns internal object state as a programmer-readable string.
- def inspect
- "#<#{self.class}: #@identifier,#@link_to_identifier>"
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/offset_rationals.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/offset_rationals.rb
deleted file mode 100644
index b1f10b2b63..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/offset_rationals.rb
+++ /dev/null
@@ -1,98 +0,0 @@
-#--
-# Copyright (c) 2006 Philip Ross
-#
-# Permission is hereby granted, free of charge, to any person obtaining a copy
-# of this software and associated documentation files (the "Software"), to deal
-# in the Software without restriction, including without limitation the rights
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-# copies of the Software, and to permit persons to whom the Software is
-# furnished to do so, subject to the following conditions:
-#
-# The above copyright notice and this permission notice shall be included in all
-# copies or substantial portions of the Software.
-#
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-# THE SOFTWARE.
-#++
-
-require 'rational'
-require 'tzinfo/ruby_core_support'
-
-module TZInfo
-
- # Provides a method for getting Rationals for a timezone offset in seconds.
- # Pre-reduced rationals are returned for all the half-hour intervals between
- # -14 and +14 hours to avoid having to call gcd at runtime.
- module OffsetRationals #:nodoc:
- @@rational_cache = {
- -50400 => RubyCoreSupport.rational_new!(-7,12),
- -48600 => RubyCoreSupport.rational_new!(-9,16),
- -46800 => RubyCoreSupport.rational_new!(-13,24),
- -45000 => RubyCoreSupport.rational_new!(-25,48),
- -43200 => RubyCoreSupport.rational_new!(-1,2),
- -41400 => RubyCoreSupport.rational_new!(-23,48),
- -39600 => RubyCoreSupport.rational_new!(-11,24),
- -37800 => RubyCoreSupport.rational_new!(-7,16),
- -36000 => RubyCoreSupport.rational_new!(-5,12),
- -34200 => RubyCoreSupport.rational_new!(-19,48),
- -32400 => RubyCoreSupport.rational_new!(-3,8),
- -30600 => RubyCoreSupport.rational_new!(-17,48),
- -28800 => RubyCoreSupport.rational_new!(-1,3),
- -27000 => RubyCoreSupport.rational_new!(-5,16),
- -25200 => RubyCoreSupport.rational_new!(-7,24),
- -23400 => RubyCoreSupport.rational_new!(-13,48),
- -21600 => RubyCoreSupport.rational_new!(-1,4),
- -19800 => RubyCoreSupport.rational_new!(-11,48),
- -18000 => RubyCoreSupport.rational_new!(-5,24),
- -16200 => RubyCoreSupport.rational_new!(-3,16),
- -14400 => RubyCoreSupport.rational_new!(-1,6),
- -12600 => RubyCoreSupport.rational_new!(-7,48),
- -10800 => RubyCoreSupport.rational_new!(-1,8),
- -9000 => RubyCoreSupport.rational_new!(-5,48),
- -7200 => RubyCoreSupport.rational_new!(-1,12),
- -5400 => RubyCoreSupport.rational_new!(-1,16),
- -3600 => RubyCoreSupport.rational_new!(-1,24),
- -1800 => RubyCoreSupport.rational_new!(-1,48),
- 0 => RubyCoreSupport.rational_new!(0,1),
- 1800 => RubyCoreSupport.rational_new!(1,48),
- 3600 => RubyCoreSupport.rational_new!(1,24),
- 5400 => RubyCoreSupport.rational_new!(1,16),
- 7200 => RubyCoreSupport.rational_new!(1,12),
- 9000 => RubyCoreSupport.rational_new!(5,48),
- 10800 => RubyCoreSupport.rational_new!(1,8),
- 12600 => RubyCoreSupport.rational_new!(7,48),
- 14400 => RubyCoreSupport.rational_new!(1,6),
- 16200 => RubyCoreSupport.rational_new!(3,16),
- 18000 => RubyCoreSupport.rational_new!(5,24),
- 19800 => RubyCoreSupport.rational_new!(11,48),
- 21600 => RubyCoreSupport.rational_new!(1,4),
- 23400 => RubyCoreSupport.rational_new!(13,48),
- 25200 => RubyCoreSupport.rational_new!(7,24),
- 27000 => RubyCoreSupport.rational_new!(5,16),
- 28800 => RubyCoreSupport.rational_new!(1,3),
- 30600 => RubyCoreSupport.rational_new!(17,48),
- 32400 => RubyCoreSupport.rational_new!(3,8),
- 34200 => RubyCoreSupport.rational_new!(19,48),
- 36000 => RubyCoreSupport.rational_new!(5,12),
- 37800 => RubyCoreSupport.rational_new!(7,16),
- 39600 => RubyCoreSupport.rational_new!(11,24),
- 41400 => RubyCoreSupport.rational_new!(23,48),
- 43200 => RubyCoreSupport.rational_new!(1,2),
- 45000 => RubyCoreSupport.rational_new!(25,48),
- 46800 => RubyCoreSupport.rational_new!(13,24),
- 48600 => RubyCoreSupport.rational_new!(9,16),
- 50400 => RubyCoreSupport.rational_new!(7,12)}
-
- # Returns a Rational expressing the fraction of a day that offset in
- # seconds represents (i.e. equivalent to Rational(offset, 86400)).
- def rational_for_offset(offset)
- @@rational_cache[offset] || Rational(offset, 86400)
- end
- module_function :rational_for_offset
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/ruby_core_support.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/ruby_core_support.rb
deleted file mode 100644
index 9a0441206b..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/ruby_core_support.rb
+++ /dev/null
@@ -1,56 +0,0 @@
-#--
-# Copyright (c) 2008 Philip Ross
-#
-# Permission is hereby granted, free of charge, to any person obtaining a copy
-# of this software and associated documentation files (the "Software"), to deal
-# in the Software without restriction, including without limitation the rights
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-# copies of the Software, and to permit persons to whom the Software is
-# furnished to do so, subject to the following conditions:
-#
-# The above copyright notice and this permission notice shall be included in all
-# copies or substantial portions of the Software.
-#
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-# THE SOFTWARE.
-#++
-
-require 'date'
-require 'rational'
-
-module TZInfo
-
- # Methods to support different versions of Ruby.
- module RubyCoreSupport #:nodoc:
-
- # Use Rational.new! for performance reasons in Ruby 1.8.
- # This has been removed from 1.9, but Rational performs better.
- if Rational.respond_to? :new!
- def self.rational_new!(numerator, denominator = 1)
- Rational.new!(numerator, denominator)
- end
- else
- def self.rational_new!(numerator, denominator = 1)
- Rational(numerator, denominator)
- end
- end
-
- # Ruby 1.8.6 introduced new! and deprecated new0.
- # Ruby 1.9.0 removed new0.
- # We still need to support new0 for older versions of Ruby.
- if DateTime.respond_to? :new!
- def self.datetime_new!(ajd = 0, of = 0, sg = Date::ITALY)
- DateTime.new!(ajd, of, sg)
- end
- else
- def self.datetime_new!(ajd = 0, of = 0, sg = Date::ITALY)
- DateTime.new0(ajd, of, sg)
- end
- end
- end
-end \ No newline at end of file
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/time_or_datetime.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/time_or_datetime.rb
deleted file mode 100644
index 264517f3ee..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/time_or_datetime.rb
+++ /dev/null
@@ -1,292 +0,0 @@
-#--
-# Copyright (c) 2006 Philip Ross
-#
-# Permission is hereby granted, free of charge, to any person obtaining a copy
-# of this software and associated documentation files (the "Software"), to deal
-# in the Software without restriction, including without limitation the rights
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-# copies of the Software, and to permit persons to whom the Software is
-# furnished to do so, subject to the following conditions:
-#
-# The above copyright notice and this permission notice shall be included in all
-# copies or substantial portions of the Software.
-#
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-# THE SOFTWARE.
-#++
-
-require 'date'
-require 'time'
-require 'tzinfo/offset_rationals'
-
-module TZInfo
- # Used by TZInfo internally to represent either a Time, DateTime or integer
- # timestamp (seconds since 1970-01-01 00:00:00).
- class TimeOrDateTime #:nodoc:
- include Comparable
-
- # Constructs a new TimeOrDateTime. timeOrDateTime can be a Time, DateTime
- # or an integer. If using a Time or DateTime, any time zone information is
- # ignored.
- def initialize(timeOrDateTime)
- @time = nil
- @datetime = nil
- @timestamp = nil
-
- if timeOrDateTime.is_a?(Time)
- @time = timeOrDateTime
- @time = Time.utc(@time.year, @time.mon, @time.mday, @time.hour, @time.min, @time.sec) unless @time.zone == 'UTC'
- @orig = @time
- elsif timeOrDateTime.is_a?(DateTime)
- @datetime = timeOrDateTime
- @datetime = @datetime.new_offset(0) unless @datetime.offset == 0
- @orig = @datetime
- else
- @timestamp = timeOrDateTime.to_i
- @orig = @timestamp
- end
- end
-
- # Returns the time as a Time.
- def to_time
- unless @time
- if @timestamp
- @time = Time.at(@timestamp).utc
- else
- @time = Time.utc(year, mon, mday, hour, min, sec)
- end
- end
-
- @time
- end
-
- # Returns the time as a DateTime.
- def to_datetime
- unless @datetime
- @datetime = DateTime.new(year, mon, mday, hour, min, sec)
- end
-
- @datetime
- end
-
- # Returns the time as an integer timestamp.
- def to_i
- unless @timestamp
- @timestamp = to_time.to_i
- end
-
- @timestamp
- end
-
- # Returns the time as the original time passed to new.
- def to_orig
- @orig
- end
-
- # Returns a string representation of the TimeOrDateTime.
- def to_s
- if @orig.is_a?(Time)
- "Time: #{@orig.to_s}"
- elsif @orig.is_a?(DateTime)
- "DateTime: #{@orig.to_s}"
- else
- "Timestamp: #{@orig.to_s}"
- end
- end
-
- # Returns internal object state as a programmer-readable string.
- def inspect
- "#<#{self.class}: #{@orig.inspect}>"
- end
-
- # Returns the year.
- def year
- if @time
- @time.year
- elsif @datetime
- @datetime.year
- else
- to_time.year
- end
- end
-
- # Returns the month of the year (1..12).
- def mon
- if @time
- @time.mon
- elsif @datetime
- @datetime.mon
- else
- to_time.mon
- end
- end
- alias :month :mon
-
- # Returns the day of the month (1..n).
- def mday
- if @time
- @time.mday
- elsif @datetime
- @datetime.mday
- else
- to_time.mday
- end
- end
- alias :day :mday
-
- # Returns the hour of the day (0..23).
- def hour
- if @time
- @time.hour
- elsif @datetime
- @datetime.hour
- else
- to_time.hour
- end
- end
-
- # Returns the minute of the hour (0..59).
- def min
- if @time
- @time.min
- elsif @datetime
- @datetime.min
- else
- to_time.min
- end
- end
-
- # Returns the second of the minute (0..60). (60 for a leap second).
- def sec
- if @time
- @time.sec
- elsif @datetime
- @datetime.sec
- else
- to_time.sec
- end
- end
-
- # Compares this TimeOrDateTime with another Time, DateTime, integer
- # timestamp or TimeOrDateTime. Returns -1, 0 or +1 depending whether the
- # receiver is less than, equal to, or greater than timeOrDateTime.
- #
- # Milliseconds and smaller units are ignored in the comparison.
- def <=>(timeOrDateTime)
- if timeOrDateTime.is_a?(TimeOrDateTime)
- orig = timeOrDateTime.to_orig
-
- if @orig.is_a?(DateTime) || orig.is_a?(DateTime)
- # If either is a DateTime, assume it is there for a reason
- # (i.e. for range).
- to_datetime <=> timeOrDateTime.to_datetime
- elsif orig.is_a?(Time)
- to_time <=> timeOrDateTime.to_time
- else
- to_i <=> timeOrDateTime.to_i
- end
- elsif @orig.is_a?(DateTime) || timeOrDateTime.is_a?(DateTime)
- # If either is a DateTime, assume it is there for a reason
- # (i.e. for range).
- to_datetime <=> TimeOrDateTime.wrap(timeOrDateTime).to_datetime
- elsif timeOrDateTime.is_a?(Time)
- to_time <=> timeOrDateTime
- else
- to_i <=> timeOrDateTime.to_i
- end
- end
-
- # Adds a number of seconds to the TimeOrDateTime. Returns a new
- # TimeOrDateTime, preserving what the original constructed type was.
- # If the original type is a Time and the resulting calculation goes out of
- # range for Times, then an exception will be raised by the Time class.
- def +(seconds)
- if seconds == 0
- self
- else
- if @orig.is_a?(DateTime)
- TimeOrDateTime.new(@orig + OffsetRationals.rational_for_offset(seconds))
- else
- # + defined for Time and integer timestamps
- TimeOrDateTime.new(@orig + seconds)
- end
- end
- end
-
- # Subtracts a number of seconds from the TimeOrDateTime. Returns a new
- # TimeOrDateTime, preserving what the original constructed type was.
- # If the original type is a Time and the resulting calculation goes out of
- # range for Times, then an exception will be raised by the Time class.
- def -(seconds)
- self + (-seconds)
- end
-
- # Similar to the + operator, but for cases where adding would cause a
- # timestamp or time to go out of the allowed range, converts to a DateTime
- # based TimeOrDateTime.
- def add_with_convert(seconds)
- if seconds == 0
- self
- else
- if @orig.is_a?(DateTime)
- TimeOrDateTime.new(@orig + OffsetRationals.rational_for_offset(seconds))
- else
- # A Time or timestamp.
- result = to_i + seconds
-
- if result < 0 || result > 2147483647
- result = TimeOrDateTime.new(to_datetime + OffsetRationals.rational_for_offset(seconds))
- else
- result = TimeOrDateTime.new(@orig + seconds)
- end
- end
- end
- end
-
- # Returns true if todt represents the same time and was originally
- # constructed with the same type (DateTime, Time or timestamp) as this
- # TimeOrDateTime.
- def eql?(todt)
- todt.respond_to?(:to_orig) && to_orig.eql?(todt.to_orig)
- end
-
- # Returns a hash of this TimeOrDateTime.
- def hash
- @orig.hash
- end
-
- # If no block is given, returns a TimeOrDateTime wrapping the given
- # timeOrDateTime. If a block is specified, a TimeOrDateTime is constructed
- # and passed to the block. The result of the block must be a TimeOrDateTime.
- # to_orig will be called on the result and the result of to_orig will be
- # returned.
- #
- # timeOrDateTime can be a Time, DateTime, integer timestamp or TimeOrDateTime.
- # If a TimeOrDateTime is passed in, no new TimeOrDateTime will be constructed,
- # the passed in value will be used.
- def self.wrap(timeOrDateTime)
- t = timeOrDateTime.is_a?(TimeOrDateTime) ? timeOrDateTime : TimeOrDateTime.new(timeOrDateTime)
-
- if block_given?
- t = yield t
-
- if timeOrDateTime.is_a?(TimeOrDateTime)
- t
- elsif timeOrDateTime.is_a?(Time)
- t.to_time
- elsif timeOrDateTime.is_a?(DateTime)
- t.to_datetime
- else
- t.to_i
- end
- else
- t
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone.rb
deleted file mode 100644
index ef4ecd8ae1..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone.rb
+++ /dev/null
@@ -1,508 +0,0 @@
-#--
-# Copyright (c) 2005-2006 Philip Ross
-#
-# Permission is hereby granted, free of charge, to any person obtaining a copy
-# of this software and associated documentation files (the "Software"), to deal
-# in the Software without restriction, including without limitation the rights
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-# copies of the Software, and to permit persons to whom the Software is
-# furnished to do so, subject to the following conditions:
-#
-# The above copyright notice and this permission notice shall be included in all
-# copies or substantial portions of the Software.
-#
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-# THE SOFTWARE.
-#++
-
-require 'date'
-# require 'tzinfo/country'
-require 'tzinfo/time_or_datetime'
-require 'tzinfo/timezone_period'
-
-module TZInfo
- # Indicate a specified time in a local timezone has more than one
- # possible time in UTC. This happens when switching from daylight savings time
- # to normal time where the clocks are rolled back. Thrown by period_for_local
- # and local_to_utc when using an ambiguous time and not specifying any
- # means to resolve the ambiguity.
- class AmbiguousTime < StandardError
- end
-
- # Thrown to indicate that no TimezonePeriod matching a given time could be found.
- class PeriodNotFound < StandardError
- end
-
- # Thrown by Timezone#get if the identifier given is not valid.
- class InvalidTimezoneIdentifier < StandardError
- end
-
- # Thrown if an attempt is made to use a timezone created with Timezone.new(nil).
- class UnknownTimezone < StandardError
- end
-
- # Timezone is the base class of all timezones. It provides a factory method
- # get to access timezones by identifier. Once a specific Timezone has been
- # retrieved, DateTimes, Times and timestamps can be converted between the UTC
- # and the local time for the zone. For example:
- #
- # tz = TZInfo::Timezone.get('America/New_York')
- # puts tz.utc_to_local(DateTime.new(2005,8,29,15,35,0)).to_s
- # puts tz.local_to_utc(Time.utc(2005,8,29,11,35,0)).to_s
- # puts tz.utc_to_local(1125315300).to_s
- #
- # Each time conversion method returns an object of the same type it was
- # passed.
- #
- # The timezone information all comes from the tz database
- # (see http://www.twinsun.com/tz/tz-link.htm)
- class Timezone
- include Comparable
-
- # Cache of loaded zones by identifier to avoid using require if a zone
- # has already been loaded.
- @@loaded_zones = {}
-
- # Whether the timezones index has been loaded yet.
- @@index_loaded = false
-
- # Returns a timezone by its identifier (e.g. "Europe/London",
- # "America/Chicago" or "UTC").
- #
- # Raises InvalidTimezoneIdentifier if the timezone couldn't be found.
- def self.get(identifier)
- instance = @@loaded_zones[identifier]
- unless instance
- raise InvalidTimezoneIdentifier, 'Invalid identifier' if identifier !~ /^[A-z0-9\+\-_]+(\/[A-z0-9\+\-_]+)*$/
- identifier = identifier.gsub(/-/, '__m__').gsub(/\+/, '__p__')
- begin
- # Use a temporary variable to avoid an rdoc warning
- file = "tzinfo/definitions/#{identifier}".untaint
- require file
-
- m = Definitions
- identifier.split(/\//).each {|part|
- m = m.const_get(part)
- }
-
- info = m.get
-
- # Could make Timezone subclasses register an interest in an info
- # type. Since there are currently only two however, there isn't
- # much point.
- if info.kind_of?(DataTimezoneInfo)
- instance = DataTimezone.new(info)
- elsif info.kind_of?(LinkedTimezoneInfo)
- instance = LinkedTimezone.new(info)
- else
- raise InvalidTimezoneIdentifier, "No handler for info type #{info.class}"
- end
-
- @@loaded_zones[instance.identifier] = instance
- rescue LoadError, NameError => e
- raise InvalidTimezoneIdentifier, e.message
- end
- end
-
- instance
- end
-
- # Returns a proxy for the Timezone with the given identifier. The proxy
- # will cause the real timezone to be loaded when an attempt is made to
- # find a period or convert a time. get_proxy will not validate the
- # identifier. If an invalid identifier is specified, no exception will be
- # raised until the proxy is used.
- def self.get_proxy(identifier)
- TimezoneProxy.new(identifier)
- end
-
- # If identifier is nil calls super(), otherwise calls get. An identfier
- # should always be passed in when called externally.
- def self.new(identifier = nil)
- if identifier
- get(identifier)
- else
- super()
- end
- end
-
- # Returns an array containing all the available Timezones.
- #
- # Returns TimezoneProxy objects to avoid the overhead of loading Timezone
- # definitions until a conversion is actually required.
- def self.all
- get_proxies(all_identifiers)
- end
-
- # Returns an array containing the identifiers of all the available
- # Timezones.
- def self.all_identifiers
- load_index
- Indexes::Timezones.timezones
- end
-
- # Returns an array containing all the available Timezones that are based
- # on data (are not links to other Timezones).
- #
- # Returns TimezoneProxy objects to avoid the overhead of loading Timezone
- # definitions until a conversion is actually required.
- def self.all_data_zones
- get_proxies(all_data_zone_identifiers)
- end
-
- # Returns an array containing the identifiers of all the available
- # Timezones that are based on data (are not links to other Timezones)..
- def self.all_data_zone_identifiers
- load_index
- Indexes::Timezones.data_timezones
- end
-
- # Returns an array containing all the available Timezones that are links
- # to other Timezones.
- #
- # Returns TimezoneProxy objects to avoid the overhead of loading Timezone
- # definitions until a conversion is actually required.
- def self.all_linked_zones
- get_proxies(all_linked_zone_identifiers)
- end
-
- # Returns an array containing the identifiers of all the available
- # Timezones that are links to other Timezones.
- def self.all_linked_zone_identifiers
- load_index
- Indexes::Timezones.linked_timezones
- end
-
- # Returns all the Timezones defined for all Countries. This is not the
- # complete set of Timezones as some are not country specific (e.g.
- # 'Etc/GMT').
- #
- # Returns TimezoneProxy objects to avoid the overhead of loading Timezone
- # definitions until a conversion is actually required.
- def self.all_country_zones
- Country.all_codes.inject([]) {|zones,country|
- zones += Country.get(country).zones
- }
- end
-
- # Returns all the zone identifiers defined for all Countries. This is not the
- # complete set of zone identifiers as some are not country specific (e.g.
- # 'Etc/GMT'). You can obtain a Timezone instance for a given identifier
- # with the get method.
- def self.all_country_zone_identifiers
- Country.all_codes.inject([]) {|zones,country|
- zones += Country.get(country).zone_identifiers
- }
- end
-
- # Returns all US Timezone instances. A shortcut for
- # TZInfo::Country.get('US').zones.
- #
- # Returns TimezoneProxy objects to avoid the overhead of loading Timezone
- # definitions until a conversion is actually required.
- def self.us_zones
- Country.get('US').zones
- end
-
- # Returns all US zone identifiers. A shortcut for
- # TZInfo::Country.get('US').zone_identifiers.
- def self.us_zone_identifiers
- Country.get('US').zone_identifiers
- end
-
- # The identifier of the timezone, e.g. "Europe/Paris".
- def identifier
- raise UnknownTimezone, 'TZInfo::Timezone constructed directly'
- end
-
- # An alias for identifier.
- def name
- # Don't use alias, as identifier gets overridden.
- identifier
- end
-
- # Returns a friendlier version of the identifier.
- def to_s
- friendly_identifier
- end
-
- # Returns internal object state as a programmer-readable string.
- def inspect
- "#<#{self.class}: #{identifier}>"
- end
-
- # Returns a friendlier version of the identifier. Set skip_first_part to
- # omit the first part of the identifier (typically a region name) where
- # there is more than one part.
- #
- # For example:
- #
- # Timezone.get('Europe/Paris').friendly_identifier(false) #=> "Europe - Paris"
- # Timezone.get('Europe/Paris').friendly_identifier(true) #=> "Paris"
- # Timezone.get('America/Indiana/Knox').friendly_identifier(false) #=> "America - Knox, Indiana"
- # Timezone.get('America/Indiana/Knox').friendly_identifier(true) #=> "Knox, Indiana"
- def friendly_identifier(skip_first_part = false)
- parts = identifier.split('/')
- if parts.empty?
- # shouldn't happen
- identifier
- elsif parts.length == 1
- parts[0]
- else
- if skip_first_part
- result = ''
- else
- result = parts[0] + ' - '
- end
-
- parts[1, parts.length - 1].reverse_each {|part|
- part.gsub!(/_/, ' ')
-
- if part.index(/[a-z]/)
- # Missing a space if a lower case followed by an upper case and the
- # name isn't McXxxx.
- part.gsub!(/([^M][a-z])([A-Z])/, '\1 \2')
- part.gsub!(/([M][a-bd-z])([A-Z])/, '\1 \2')
-
- # Missing an apostrophe if two consecutive upper case characters.
- part.gsub!(/([A-Z])([A-Z])/, '\1\'\2')
- end
-
- result << part
- result << ', '
- }
-
- result.slice!(result.length - 2, 2)
- result
- end
- end
-
- # Returns the TimezonePeriod for the given UTC time. utc can either be
- # a DateTime, Time or integer timestamp (Time.to_i). Any timezone
- # information in utc is ignored (it is treated as a UTC time).
- def period_for_utc(utc)
- raise UnknownTimezone, 'TZInfo::Timezone constructed directly'
- end
-
- # Returns the set of TimezonePeriod instances that are valid for the given
- # local time as an array. If you just want a single period, use
- # period_for_local instead and specify how ambiguities should be resolved.
- # Returns an empty array if no periods are found for the given time.
- def periods_for_local(local)
- raise UnknownTimezone, 'TZInfo::Timezone constructed directly'
- end
-
- # Returns the TimezonePeriod for the given local time. local can either be
- # a DateTime, Time or integer timestamp (Time.to_i). Any timezone
- # information in local is ignored (it is treated as a time in the current
- # timezone).
- #
- # Warning: There are local times that have no equivalent UTC times (e.g.
- # in the transition from standard time to daylight savings time). There are
- # also local times that have more than one UTC equivalent (e.g. in the
- # transition from daylight savings time to standard time).
- #
- # In the first case (no equivalent UTC time), a PeriodNotFound exception
- # will be raised.
- #
- # In the second case (more than one equivalent UTC time), an AmbiguousTime
- # exception will be raised unless the optional dst parameter or block
- # handles the ambiguity.
- #
- # If the ambiguity is due to a transition from daylight savings time to
- # standard time, the dst parameter can be used to select whether the
- # daylight savings time or local time is used. For example,
- #
- # Timezone.get('America/New_York').period_for_local(DateTime.new(2004,10,31,1,30,0))
- #
- # would raise an AmbiguousTime exception.
- #
- # Specifying dst=true would the daylight savings period from April to
- # October 2004. Specifying dst=false would return the standard period
- # from October 2004 to April 2005.
- #
- # If the dst parameter does not resolve the ambiguity, and a block is
- # specified, it is called. The block must take a single parameter - an
- # array of the periods that need to be resolved. The block can select and
- # return a single period or return nil or an empty array
- # to cause an AmbiguousTime exception to be raised.
- def period_for_local(local, dst = nil)
- results = periods_for_local(local)
-
- if results.empty?
- raise PeriodNotFound
- elsif results.size < 2
- results.first
- else
- # ambiguous result try to resolve
-
- if !dst.nil?
- matches = results.find_all {|period| period.dst? == dst}
- results = matches if !matches.empty?
- end
-
- if results.size < 2
- results.first
- else
- # still ambiguous, try the block
-
- if block_given?
- results = yield results
- end
-
- if results.is_a?(TimezonePeriod)
- results
- elsif results && results.size == 1
- results.first
- else
- raise AmbiguousTime, "#{local} is an ambiguous local time."
- end
- end
- end
- end
-
- # Converts a time in UTC to the local timezone. utc can either be
- # a DateTime, Time or timestamp (Time.to_i). The returned time has the same
- # type as utc. Any timezone information in utc is ignored (it is treated as
- # a UTC time).
- def utc_to_local(utc)
- TimeOrDateTime.wrap(utc) {|wrapped|
- period_for_utc(wrapped).to_local(wrapped)
- }
- end
-
- # Converts a time in the local timezone to UTC. local can either be
- # a DateTime, Time or timestamp (Time.to_i). The returned time has the same
- # type as local. Any timezone information in local is ignored (it is treated
- # as a local time).
- #
- # Warning: There are local times that have no equivalent UTC times (e.g.
- # in the transition from standard time to daylight savings time). There are
- # also local times that have more than one UTC equivalent (e.g. in the
- # transition from daylight savings time to standard time).
- #
- # In the first case (no equivalent UTC time), a PeriodNotFound exception
- # will be raised.
- #
- # In the second case (more than one equivalent UTC time), an AmbiguousTime
- # exception will be raised unless the optional dst parameter or block
- # handles the ambiguity.
- #
- # If the ambiguity is due to a transition from daylight savings time to
- # standard time, the dst parameter can be used to select whether the
- # daylight savings time or local time is used. For example,
- #
- # Timezone.get('America/New_York').local_to_utc(DateTime.new(2004,10,31,1,30,0))
- #
- # would raise an AmbiguousTime exception.
- #
- # Specifying dst=true would return 2004-10-31 5:30:00. Specifying dst=false
- # would return 2004-10-31 6:30:00.
- #
- # If the dst parameter does not resolve the ambiguity, and a block is
- # specified, it is called. The block must take a single parameter - an
- # array of the periods that need to be resolved. The block can return a
- # single period to use to convert the time or return nil or an empty array
- # to cause an AmbiguousTime exception to be raised.
- def local_to_utc(local, dst = nil)
- TimeOrDateTime.wrap(local) {|wrapped|
- if block_given?
- period = period_for_local(wrapped, dst) {|periods| yield periods }
- else
- period = period_for_local(wrapped, dst)
- end
-
- period.to_utc(wrapped)
- }
- end
-
- # Returns the current time in the timezone as a Time.
- def now
- utc_to_local(Time.now.utc)
- end
-
- # Returns the TimezonePeriod for the current time.
- def current_period
- period_for_utc(Time.now.utc)
- end
-
- # Returns the current Time and TimezonePeriod as an array. The first element
- # is the time, the second element is the period.
- def current_period_and_time
- utc = Time.now.utc
- period = period_for_utc(utc)
- [period.to_local(utc), period]
- end
-
- alias :current_time_and_period :current_period_and_time
-
- # Converts a time in UTC to local time and returns it as a string
- # according to the given format. The formatting is identical to
- # Time.strftime and DateTime.strftime, except %Z is replaced with the
- # timezone abbreviation for the specified time (for example, EST or EDT).
- def strftime(format, utc = Time.now.utc)
- period = period_for_utc(utc)
- local = period.to_local(utc)
- local = Time.at(local).utc unless local.kind_of?(Time) || local.kind_of?(DateTime)
- abbreviation = period.abbreviation.to_s.gsub(/%/, '%%')
-
- format = format.gsub(/(.?)%Z/) do
- if $1 == '%'
- # return %%Z so the real strftime treats it as a literal %Z too
- '%%Z'
- else
- "#$1#{abbreviation}"
- end
- end
-
- local.strftime(format)
- end
-
- # Compares two Timezones based on their identifier. Returns -1 if tz is less
- # than self, 0 if tz is equal to self and +1 if tz is greater than self.
- def <=>(tz)
- identifier <=> tz.identifier
- end
-
- # Returns true if and only if the identifier of tz is equal to the
- # identifier of this Timezone.
- def eql?(tz)
- self == tz
- end
-
- # Returns a hash of this Timezone.
- def hash
- identifier.hash
- end
-
- # Dumps this Timezone for marshalling.
- def _dump(limit)
- identifier
- end
-
- # Loads a marshalled Timezone.
- def self._load(data)
- Timezone.get(data)
- end
-
- private
- # Loads in the index of timezones if it hasn't already been loaded.
- def self.load_index
- unless @@index_loaded
- require 'tzinfo/indexes/timezones'
- @@index_loaded = true
- end
- end
-
- # Returns an array of proxies corresponding to the given array of
- # identifiers.
- def self.get_proxies(identifiers)
- identifiers.collect {|identifier| get_proxy(identifier)}
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone_definition.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone_definition.rb
deleted file mode 100644
index 39ca8bfa53..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone_definition.rb
+++ /dev/null
@@ -1,56 +0,0 @@
-#--
-# Copyright (c) 2006 Philip Ross
-#
-# Permission is hereby granted, free of charge, to any person obtaining a copy
-# of this software and associated documentation files (the "Software"), to deal
-# in the Software without restriction, including without limitation the rights
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-# copies of the Software, and to permit persons to whom the Software is
-# furnished to do so, subject to the following conditions:
-#
-# The above copyright notice and this permission notice shall be included in all
-# copies or substantial portions of the Software.
-#
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-# THE SOFTWARE.
-#++
-
-require 'tzinfo/data_timezone_info'
-require 'tzinfo/linked_timezone_info'
-
-module TZInfo
-
- # TimezoneDefinition is included into Timezone definition modules.
- # TimezoneDefinition provides the methods for defining timezones.
- module TimezoneDefinition #:nodoc:
- # Add class methods to the includee.
- def self.append_features(base)
- super
- base.extend(ClassMethods)
- end
-
- # Class methods for inclusion.
- module ClassMethods #:nodoc:
- # Returns and yields a DataTimezoneInfo object to define a timezone.
- def timezone(identifier)
- yield @timezone = DataTimezoneInfo.new(identifier)
- end
-
- # Defines a linked timezone.
- def linked_timezone(identifier, link_to_identifier)
- @timezone = LinkedTimezoneInfo.new(identifier, link_to_identifier)
- end
-
- # Returns the last TimezoneInfo to be defined with timezone or
- # linked_timezone.
- def get
- @timezone
- end
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone_info.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone_info.rb
deleted file mode 100644
index 68e38c35fb..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone_info.rb
+++ /dev/null
@@ -1,40 +0,0 @@
-#--
-# Copyright (c) 2006 Philip Ross
-#
-# Permission is hereby granted, free of charge, to any person obtaining a copy
-# of this software and associated documentation files (the "Software"), to deal
-# in the Software without restriction, including without limitation the rights
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-# copies of the Software, and to permit persons to whom the Software is
-# furnished to do so, subject to the following conditions:
-#
-# The above copyright notice and this permission notice shall be included in all
-# copies or substantial portions of the Software.
-#
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-# THE SOFTWARE.
-#++
-
-module TZInfo
- # Represents a timezone defined in a data module.
- class TimezoneInfo #:nodoc:
-
- # The timezone identifier.
- attr_reader :identifier
-
- # Constructs a new TimezoneInfo with an identifier.
- def initialize(identifier)
- @identifier = identifier
- end
-
- # Returns internal object state as a programmer-readable string.
- def inspect
- "#<#{self.class}: #@identifier>"
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone_offset_info.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone_offset_info.rb
deleted file mode 100644
index 6a0bbca46f..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone_offset_info.rb
+++ /dev/null
@@ -1,94 +0,0 @@
-#--
-# Copyright (c) 2006 Philip Ross
-#
-# Permission is hereby granted, free of charge, to any person obtaining a copy
-# of this software and associated documentation files (the "Software"), to deal
-# in the Software without restriction, including without limitation the rights
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-# copies of the Software, and to permit persons to whom the Software is
-# furnished to do so, subject to the following conditions:
-#
-# The above copyright notice and this permission notice shall be included in all
-# copies or substantial portions of the Software.
-#
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-# THE SOFTWARE.
-#++
-
-module TZInfo
- # Represents an offset defined in a Timezone data file.
- class TimezoneOffsetInfo #:nodoc:
- # The base offset of the timezone from UTC in seconds.
- attr_reader :utc_offset
-
- # The offset from standard time for the zone in seconds (i.e. non-zero if
- # daylight savings is being observed).
- attr_reader :std_offset
-
- # The total offset of this observance from UTC in seconds
- # (utc_offset + std_offset).
- attr_reader :utc_total_offset
-
- # The abbreviation that identifies this observance, e.g. "GMT"
- # (Greenwich Mean Time) or "BST" (British Summer Time) for "Europe/London". The returned identifier is a
- # symbol.
- attr_reader :abbreviation
-
- # Constructs a new TimezoneOffsetInfo. utc_offset and std_offset are
- # specified in seconds.
- def initialize(utc_offset, std_offset, abbreviation)
- @utc_offset = utc_offset
- @std_offset = std_offset
- @abbreviation = abbreviation
-
- @utc_total_offset = @utc_offset + @std_offset
- end
-
- # True if std_offset is non-zero.
- def dst?
- @std_offset != 0
- end
-
- # Converts a UTC DateTime to local time based on the offset of this period.
- def to_local(utc)
- TimeOrDateTime.wrap(utc) {|wrapped|
- wrapped + @utc_total_offset
- }
- end
-
- # Converts a local DateTime to UTC based on the offset of this period.
- def to_utc(local)
- TimeOrDateTime.wrap(local) {|wrapped|
- wrapped - @utc_total_offset
- }
- end
-
- # Returns true if and only if toi has the same utc_offset, std_offset
- # and abbreviation as this TimezoneOffsetInfo.
- def ==(toi)
- toi.respond_to?(:utc_offset) && toi.respond_to?(:std_offset) && toi.respond_to?(:abbreviation) &&
- utc_offset == toi.utc_offset && std_offset == toi.std_offset && abbreviation == toi.abbreviation
- end
-
- # Returns true if and only if toi has the same utc_offset, std_offset
- # and abbreviation as this TimezoneOffsetInfo.
- def eql?(toi)
- self == toi
- end
-
- # Returns a hash of this TimezoneOffsetInfo.
- def hash
- utc_offset.hash ^ std_offset.hash ^ abbreviation.hash
- end
-
- # Returns internal object state as a programmer-readable string.
- def inspect
- "#<#{self.class}: #@utc_offset,#@std_offset,#@abbreviation>"
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone_period.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone_period.rb
deleted file mode 100644
index 00888fcfdc..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone_period.rb
+++ /dev/null
@@ -1,198 +0,0 @@
-#--
-# Copyright (c) 2005-2006 Philip Ross
-#
-# Permission is hereby granted, free of charge, to any person obtaining a copy
-# of this software and associated documentation files (the "Software"), to deal
-# in the Software without restriction, including without limitation the rights
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-# copies of the Software, and to permit persons to whom the Software is
-# furnished to do so, subject to the following conditions:
-#
-# The above copyright notice and this permission notice shall be included in all
-# copies or substantial portions of the Software.
-#
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-# THE SOFTWARE.
-#++
-
-require 'tzinfo/offset_rationals'
-require 'tzinfo/time_or_datetime'
-
-module TZInfo
- # A period of time in a timezone where the same offset from UTC applies.
- #
- # All the methods that take times accept instances of Time, DateTime or
- # integer timestamps.
- class TimezonePeriod
- # The TimezoneTransitionInfo that defines the start of this TimezonePeriod
- # (may be nil if unbounded).
- attr_reader :start_transition
-
- # The TimezoneTransitionInfo that defines the end of this TimezonePeriod
- # (may be nil if unbounded).
- attr_reader :end_transition
-
- # The TimezoneOffsetInfo for this period.
- attr_reader :offset
-
- # Initializes a new TimezonePeriod.
- def initialize(start_transition, end_transition, offset = nil)
- @start_transition = start_transition
- @end_transition = end_transition
-
- if offset
- raise ArgumentError, 'Offset specified with transitions' if @start_transition || @end_transition
- @offset = offset
- else
- if @start_transition
- @offset = @start_transition.offset
- elsif @end_transition
- @offset = @end_transition.previous_offset
- else
- raise ArgumentError, 'No offset specified and no transitions to determine it from'
- end
- end
-
- @utc_total_offset_rational = nil
- end
-
- # Base offset of the timezone from UTC (seconds).
- def utc_offset
- @offset.utc_offset
- end
-
- # Offset from the local time where daylight savings is in effect (seconds).
- # E.g.: utc_offset could be -5 hours. Normally, std_offset would be 0.
- # During daylight savings, std_offset would typically become +1 hours.
- def std_offset
- @offset.std_offset
- end
-
- # The identifier of this period, e.g. "GMT" (Greenwich Mean Time) or "BST"
- # (British Summer Time) for "Europe/London". The returned identifier is a
- # symbol.
- def abbreviation
- @offset.abbreviation
- end
- alias :zone_identifier :abbreviation
-
- # Total offset from UTC (seconds). Equal to utc_offset + std_offset.
- def utc_total_offset
- @offset.utc_total_offset
- end
-
- # Total offset from UTC (days). Result is a Rational.
- def utc_total_offset_rational
- unless @utc_total_offset_rational
- @utc_total_offset_rational = OffsetRationals.rational_for_offset(utc_total_offset)
- end
- @utc_total_offset_rational
- end
-
- # The start time of the period in UTC as a DateTime. May be nil if unbounded.
- def utc_start
- @start_transition ? @start_transition.at.to_datetime : nil
- end
-
- # The end time of the period in UTC as a DateTime. May be nil if unbounded.
- def utc_end
- @end_transition ? @end_transition.at.to_datetime : nil
- end
-
- # The start time of the period in local time as a DateTime. May be nil if
- # unbounded.
- def local_start
- @start_transition ? @start_transition.local_start.to_datetime : nil
- end
-
- # The end time of the period in local time as a DateTime. May be nil if
- # unbounded.
- def local_end
- @end_transition ? @end_transition.local_end.to_datetime : nil
- end
-
- # true if daylight savings is in effect for this period; otherwise false.
- def dst?
- @offset.dst?
- end
-
- # true if this period is valid for the given UTC DateTime; otherwise false.
- def valid_for_utc?(utc)
- utc_after_start?(utc) && utc_before_end?(utc)
- end
-
- # true if the given UTC DateTime is after the start of the period
- # (inclusive); otherwise false.
- def utc_after_start?(utc)
- !@start_transition || @start_transition.at <= utc
- end
-
- # true if the given UTC DateTime is before the end of the period
- # (exclusive); otherwise false.
- def utc_before_end?(utc)
- !@end_transition || @end_transition.at > utc
- end
-
- # true if this period is valid for the given local DateTime; otherwise false.
- def valid_for_local?(local)
- local_after_start?(local) && local_before_end?(local)
- end
-
- # true if the given local DateTime is after the start of the period
- # (inclusive); otherwise false.
- def local_after_start?(local)
- !@start_transition || @start_transition.local_start <= local
- end
-
- # true if the given local DateTime is before the end of the period
- # (exclusive); otherwise false.
- def local_before_end?(local)
- !@end_transition || @end_transition.local_end > local
- end
-
- # Converts a UTC DateTime to local time based on the offset of this period.
- def to_local(utc)
- @offset.to_local(utc)
- end
-
- # Converts a local DateTime to UTC based on the offset of this period.
- def to_utc(local)
- @offset.to_utc(local)
- end
-
- # Returns true if this TimezonePeriod is equal to p. This compares the
- # start_transition, end_transition and offset using ==.
- def ==(p)
- p.respond_to?(:start_transition) && p.respond_to?(:end_transition) &&
- p.respond_to?(:offset) && start_transition == p.start_transition &&
- end_transition == p.end_transition && offset == p.offset
- end
-
- # Returns true if this TimezonePeriods is equal to p. This compares the
- # start_transition, end_transition and offset using eql?
- def eql?(p)
- p.respond_to?(:start_transition) && p.respond_to?(:end_transition) &&
- p.respond_to?(:offset) && start_transition.eql?(p.start_transition) &&
- end_transition.eql?(p.end_transition) && offset.eql?(p.offset)
- end
-
- # Returns a hash of this TimezonePeriod.
- def hash
- result = @start_transition.hash ^ @end_transition.hash
- result ^= @offset.hash unless @start_transition || @end_transition
- result
- end
-
- # Returns internal object state as a programmer-readable string.
- def inspect
- result = "#<#{self.class}: #{@start_transition.inspect},#{@end_transition.inspect}"
- result << ",#{@offset.inspect}>" unless @start_transition || @end_transition
- result + '>'
- end
- end
-end
diff --git a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone_transition_info.rb b/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone_transition_info.rb
deleted file mode 100644
index 6b0669cc4a..0000000000
--- a/activesupport/lib/active_support/vendor/tzinfo-0.3.15/lib/tzinfo/timezone_transition_info.rb
+++ /dev/null
@@ -1,129 +0,0 @@
-#--
-# Copyright (c) 2006 Philip Ross
-#
-# Permission is hereby granted, free of charge, to any person obtaining a copy
-# of this software and associated documentation files (the "Software"), to deal
-# in the Software without restriction, including without limitation the rights
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-# copies of the Software, and to permit persons to whom the Software is
-# furnished to do so, subject to the following conditions:
-#
-# The above copyright notice and this permission notice shall be included in all
-# copies or substantial portions of the Software.
-#
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-# THE SOFTWARE.
-#++
-
-require 'date'
-require 'tzinfo/time_or_datetime'
-
-module TZInfo
- # Represents an offset defined in a Timezone data file.
- class TimezoneTransitionInfo #:nodoc:
- # The offset this transition changes to (a TimezoneOffsetInfo instance).
- attr_reader :offset
-
- # The offset this transition changes from (a TimezoneOffsetInfo instance).
- attr_reader :previous_offset
-
- # The numerator of the DateTime if the transition time is defined as a
- # DateTime, otherwise the transition time as a timestamp.
- attr_reader :numerator_or_time
- protected :numerator_or_time
-
- # Either the denominotor of the DateTime if the transition time is defined
- # as a DateTime, otherwise nil.
- attr_reader :denominator
- protected :denominator
-
- # Creates a new TimezoneTransitionInfo with the given offset,
- # previous_offset (both TimezoneOffsetInfo instances) and UTC time.
- # if denominator is nil, numerator_or_time is treated as a number of
- # seconds since the epoch. If denominator is specified numerator_or_time
- # and denominator are used to create a DateTime as follows:
- #
- # DateTime.new!(Rational.send(:new!, numerator_or_time, denominator), 0, Date::ITALY)
- #
- # For performance reasons, the numerator and denominator must be specified
- # in their lowest form.
- def initialize(offset, previous_offset, numerator_or_time, denominator = nil)
- @offset = offset
- @previous_offset = previous_offset
- @numerator_or_time = numerator_or_time
- @denominator = denominator
-
- @at = nil
- @local_end = nil
- @local_start = nil
- end
-
- # A TimeOrDateTime instance representing the UTC time when this transition
- # occurs.
- def at
- unless @at
- unless @denominator
- @at = TimeOrDateTime.new(@numerator_or_time)
- else
- r = RubyCoreSupport.rational_new!(@numerator_or_time, @denominator)
- dt = RubyCoreSupport.datetime_new!(r, 0, Date::ITALY)
- @at = TimeOrDateTime.new(dt)
- end
- end
-
- @at
- end
-
- # A TimeOrDateTime instance representing the local time when this transition
- # causes the previous observance to end (calculated from at using
- # previous_offset).
- def local_end
- @local_end = at.add_with_convert(@previous_offset.utc_total_offset) unless @local_end
- @local_end
- end
-
- # A TimeOrDateTime instance representing the local time when this transition
- # causes the next observance to start (calculated from at using offset).
- def local_start
- @local_start = at.add_with_convert(@offset.utc_total_offset) unless @local_start
- @local_start
- end
-
- # Returns true if this TimezoneTransitionInfo is equal to the given
- # TimezoneTransitionInfo. Two TimezoneTransitionInfo instances are
- # considered to be equal by == if offset, previous_offset and at are all
- # equal.
- def ==(tti)
- tti.respond_to?(:offset) && tti.respond_to?(:previous_offset) && tti.respond_to?(:at) &&
- offset == tti.offset && previous_offset == tti.previous_offset && at == tti.at
- end
-
- # Returns true if this TimezoneTransitionInfo is equal to the given
- # TimezoneTransitionInfo. Two TimezoneTransitionInfo instances are
- # considered to be equal by eql? if offset, previous_offset,
- # numerator_or_time and denominator are all equal. This is stronger than ==,
- # which just requires the at times to be equal regardless of how they were
- # originally specified.
- def eql?(tti)
- tti.respond_to?(:offset) && tti.respond_to?(:previous_offset) &&
- tti.respond_to?(:numerator_or_time) && tti.respond_to?(:denominator) &&
- offset == tti.offset && previous_offset == tti.previous_offset &&
- numerator_or_time == tti.numerator_or_time && denominator == tti.denominator
- end
-
- # Returns a hash of this TimezoneTransitionInfo instance.
- def hash
- @offset.hash ^ @previous_offset.hash ^ @numerator_or_time.hash ^ @denominator.hash
- end
-
- # Returns internal object state as a programmer-readable string.
- def inspect
- "#<#{self.class}: #{at.inspect},#{@offset.inspect}>"
- end
- end
-end
diff --git a/activesupport/test/core_ext/array_ext_test.rb b/activesupport/test/core_ext/array_ext_test.rb
index f5f91ddd80..d4cd5ddbde 100644
--- a/activesupport/test/core_ext/array_ext_test.rb
+++ b/activesupport/test/core_ext/array_ext_test.rb
@@ -52,8 +52,6 @@ class ArrayExtToParamTests < Test::Unit::TestCase
end
class ArrayExtToSentenceTests < Test::Unit::TestCase
- include ActiveSupport::Testing::Deprecation
-
def test_plain_array_to_sentence
assert_equal "", [].to_sentence
assert_equal "one", ['one'].to_sentence
@@ -62,28 +60,12 @@ class ArrayExtToSentenceTests < Test::Unit::TestCase
end
def test_to_sentence_with_words_connector
- assert_deprecated(":connector has been deprecated. Use :words_connector instead") do
- assert_equal "one, two, three", ['one', 'two', 'three'].to_sentence(:connector => '')
- end
-
- assert_deprecated(":connector has been deprecated. Use :words_connector instead") do
- assert_equal "one, two, and three", ['one', 'two', 'three'].to_sentence(:connector => 'and ')
- end
-
assert_equal "one two, and three", ['one', 'two', 'three'].to_sentence(:words_connector => ' ')
assert_equal "one & two, and three", ['one', 'two', 'three'].to_sentence(:words_connector => ' & ')
assert_equal "onetwo, and three", ['one', 'two', 'three'].to_sentence(:words_connector => nil)
end
def test_to_sentence_with_last_word_connector
- assert_deprecated(":skip_last_comma has been deprecated. Use :last_word_connector instead") do
- assert_equal "one, two and three", ['one', 'two', 'three'].to_sentence(:skip_last_comma => true)
- end
-
- assert_deprecated(":skip_last_comma has been deprecated. Use :last_word_connector instead") do
- assert_equal "one, two, and three", ['one', 'two', 'three'].to_sentence(:skip_last_comma => false)
- end
-
assert_equal "one, two, and also three", ['one', 'two', 'three'].to_sentence(:last_word_connector => ', and also ')
assert_equal "one, twothree", ['one', 'two', 'three'].to_sentence(:last_word_connector => nil)
assert_equal "one, two three", ['one', 'two', 'three'].to_sentence(:last_word_connector => ' ')
@@ -320,6 +302,28 @@ class ArrayExtractOptionsTests < Test::Unit::TestCase
end
end
+class ArrayUniqByTests < Test::Unit::TestCase
+ def test_uniq_by
+ assert_equal [1,2], [1,2,3,4].uniq_by { |i| i.odd? }
+ assert_equal [1,2], [1,2,3,4].uniq_by(&:even?)
+ assert_equal (-5..0).to_a, (-5..5).to_a.uniq_by{ |i| i**2 }
+ end
+
+ def test_uniq_by!
+ a = [1,2,3,4]
+ a.uniq_by! { |i| i.odd? }
+ assert_equal [1,2], a
+
+ a = [1,2,3,4]
+ a.uniq_by! { |i| i.even? }
+ assert_equal [1,2], a
+
+ a = (-5..5).to_a
+ a.uniq_by! { |i| i**2 }
+ assert_equal (-5..0).to_a, a
+ end
+end
+
class ArrayExtRandomTests < Test::Unit::TestCase
def test_random_element_from_array
assert_nil [].rand
diff --git a/activesupport/test/core_ext/class_test.rb b/activesupport/test/core_ext/class_test.rb
deleted file mode 100644
index bb4eb3c7d5..0000000000
--- a/activesupport/test/core_ext/class_test.rb
+++ /dev/null
@@ -1,47 +0,0 @@
-require 'abstract_unit'
-require 'active_support/core_ext/class'
-
-class A
-end
-
-module X
- class B
- end
-end
-
-module Y
- module Z
- class C
- end
- end
-end
-
-class ClassTest < Test::Unit::TestCase
- def test_removing_class_in_root_namespace
- assert A.is_a?(Class)
- Class.remove_class(A)
- assert_raise(NameError) { A.is_a?(Class) }
- end
-
- def test_removing_class_in_one_level_namespace
- assert X::B.is_a?(Class)
- Class.remove_class(X::B)
- assert_raise(NameError) { X::B.is_a?(Class) }
- end
-
- def test_removing_class_in_two_level_namespace
- assert Y::Z::C.is_a?(Class)
- Class.remove_class(Y::Z::C)
- assert_raise(NameError) { Y::Z::C.is_a?(Class) }
- end
-
- def test_retrieving_subclasses
- @parent = eval("class D; end; D")
- @sub = eval("class E < D; end; E")
- @subofsub = eval("class F < E; end; F")
- assert_equal 2, @parent.subclasses.size
- assert_equal [@subofsub.to_s], @sub.subclasses
- assert_equal [], @subofsub.subclasses
- assert_equal [@sub.to_s, @subofsub.to_s].sort, @parent.subclasses.sort
- end
-end
diff --git a/activesupport/test/core_ext/object_and_class_ext_test.rb b/activesupport/test/core_ext/object_and_class_ext_test.rb
index e6fbdb637b..0b2a9c418e 100644
--- a/activesupport/test/core_ext/object_and_class_ext_test.rb
+++ b/activesupport/test/core_ext/object_and_class_ext_test.rb
@@ -1,7 +1,6 @@
require 'abstract_unit'
require 'active_support/time'
require 'active_support/core_ext/object'
-require 'active_support/core_ext/class/removal'
class ClassA; end
class ClassB < ClassA; end
@@ -40,99 +39,7 @@ class Foo
include Bar
end
-class ClassExtTest < Test::Unit::TestCase
- def test_methods
- assert defined?(ClassB)
- assert defined?(ClassC)
- assert defined?(ClassD)
-
- ClassA.remove_subclasses
-
- assert !defined?(ClassB)
- assert !defined?(ClassC)
- assert !defined?(ClassD)
- end
-
- def test_subclasses_of
- cj = ClassJ
- assert_equal [ClassJ], Object.subclasses_of(ClassI)
- ClassI.remove_subclasses
- assert_equal [], Object.subclasses_of(ClassI)
- ensure
- Object.const_set :ClassJ, cj
- end
-
- def test_subclasses_of_should_find_nested_classes
- assert Object.subclasses_of(ClassK).include?(Nested::ClassL)
- end
-
- def test_subclasses_of_should_not_return_removed_classes
- # First create the removed class
- old_class = Nested.class_eval { remove_const :ClassL }
- new_class = Class.new(ClassK)
- Nested.const_set :ClassL, new_class
- assert_equal "Nested::ClassL", new_class.name # Sanity check
-
- subclasses = Object.subclasses_of(ClassK)
- assert subclasses.include?(new_class)
- assert ! subclasses.include?(old_class)
- ensure
- Nested.const_set :ClassL, old_class unless defined?(Nested::ClassL)
- end
-
- def test_subclasses_of_should_not_trigger_const_missing
- const_missing = false
- Nested.on_const_missing { const_missing = true }
-
- subclasses = Object.subclasses_of ClassK
- assert !const_missing
- assert_equal [ Nested::ClassL ], subclasses
-
- removed = Nested.class_eval { remove_const :ClassL } # keep it in memory
- subclasses = Object.subclasses_of ClassK
- assert !const_missing
- assert subclasses.empty?
- ensure
- Nested.const_set :ClassL, removed unless defined?(Nested::ClassL)
- end
-
- def test_subclasses_of_with_multiple_roots
- classes = Object.subclasses_of(ClassI, ClassK)
- assert_equal %w(ClassJ Nested::ClassL), classes.collect(&:to_s).sort
- end
-
- def test_subclasses_of_doesnt_find_anonymous_classes
- assert_equal [], Object.subclasses_of(Foo)
- bar = Class.new(Foo)
- assert_nothing_raised do
- assert_equal [bar], Object.subclasses_of(Foo)
- end
- end
-end
-
class ObjectTests < Test::Unit::TestCase
- def test_extended_by
- foo = Foo.new
- assert foo.extended_by.include?(Bar)
- foo.extend(Baz)
- assert(([Bar, Baz] - foo.extended_by).empty?, "Expected Bar, Baz in #{foo.extended_by.inspect}")
- end
-
- def test_extend_with_included_modules_from
- foo, object = Foo.new, Object.new
- assert !object.respond_to?(:bar)
- assert !object.respond_to?(:baz)
-
- object.extend_with_included_modules_from(foo)
- assert object.respond_to?(:bar)
- assert !object.respond_to?(:baz)
-
- foo.extend(Baz)
- object.extend_with_included_modules_from(foo)
- assert object.respond_to?(:bar)
- assert object.respond_to?(:baz)
- end
-
class DuckTime
def acts_like_time?
true
diff --git a/activesupport/test/core_ext/time_ext_test.rb b/activesupport/test/core_ext/time_ext_test.rb
index f6003bc083..08c079e113 100644
--- a/activesupport/test/core_ext/time_ext_test.rb
+++ b/activesupport/test/core_ext/time_ext_test.rb
@@ -722,6 +722,10 @@ class TimeExtCalculationsTest < Test::Unit::TestCase
def test_minus_with_time_with_zone
assert_equal 86_400.0, Time.utc(2000, 1, 2) - ActiveSupport::TimeWithZone.new( Time.utc(2000, 1, 1), ActiveSupport::TimeZone['UTC'] )
end
+
+ def test_minus_with_datetime
+ assert_equal 86_400.0, Time.utc(2000, 1, 2) - DateTime.civil(2000, 1, 1)
+ end
def test_time_created_with_local_constructor_cannot_represent_times_during_hour_skipped_by_dst
with_env_tz 'US/Eastern' do
diff --git a/activesupport/test/core_ext/time_with_zone_test.rb b/activesupport/test/core_ext/time_with_zone_test.rb
index 3a12100e86..d88f79ae4f 100644
--- a/activesupport/test/core_ext/time_with_zone_test.rb
+++ b/activesupport/test/core_ext/time_with_zone_test.rb
@@ -56,8 +56,11 @@ class TimeWithZoneTest < Test::Unit::TestCase
assert_equal 'EDT', ActiveSupport::TimeWithZone.new(Time.utc(2000, 6), @time_zone).zone #dst
end
- def test_to_json
+ def test_to_json_with_use_standard_json_time_format_config_set_to_false
+ old, ActiveSupport.use_standard_json_time_format = ActiveSupport.use_standard_json_time_format, false
assert_equal "\"1999/12/31 19:00:00 -0500\"", ActiveSupport::JSON.encode(@twz)
+ ensure
+ ActiveSupport.use_standard_json_time_format = old
end
def test_to_json_with_use_standard_json_time_format_config_set_to_true
diff --git a/activesupport/test/ordered_hash_test.rb b/activesupport/test/ordered_hash_test.rb
index 1521279437..d070206d44 100644
--- a/activesupport/test/ordered_hash_test.rb
+++ b/activesupport/test/ordered_hash_test.rb
@@ -198,4 +198,28 @@ class OrderedHashTest < Test::Unit::TestCase
assert_same original, @ordered_hash
assert_equal @other_ordered_hash.keys, @ordered_hash.keys
end
+
+ def test_each_after_yaml_serialization
+ values = []
+ @deserialized_ordered_hash = YAML::load(YAML::dump(@ordered_hash))
+
+ @deserialized_ordered_hash.each {|key, value| values << value}
+ assert_equal @values, values
+ end
+
+ def test_order_after_yaml_serialization
+ @deserialized_ordered_hash = YAML::load(YAML::dump(@ordered_hash))
+
+ assert_equal @keys, @deserialized_ordered_hash.keys
+ assert_equal @values, @deserialized_ordered_hash.values
+ end
+
+ def test_order_after_yaml_serialization_with_nested_arrays
+ @ordered_hash[:array] = %w(a b c)
+
+ @deserialized_ordered_hash = YAML::load(YAML::dump(@ordered_hash))
+
+ assert_equal @ordered_hash.keys, @deserialized_ordered_hash.keys
+ assert_equal @ordered_hash.values, @deserialized_ordered_hash.values
+ end
end
diff --git a/railties/lib/generators/erb/mailer/mailer_generator.rb b/railties/lib/generators/erb/mailer/mailer_generator.rb
index 4ec2f4c9f4..408c942cef 100644
--- a/railties/lib/generators/erb/mailer/mailer_generator.rb
+++ b/railties/lib/generators/erb/mailer/mailer_generator.rb
@@ -12,7 +12,7 @@ module Erb
def create_view_files
actions.each do |action|
@action, @path = action, File.join(file_path, action)
- template "view.erb", File.join("app/views", "#{@path}.erb")
+ template "view.text.erb", File.join("app/views", "#{@path}.text.erb")
end
end
end
diff --git a/railties/lib/generators/erb/mailer/templates/view.erb b/railties/lib/generators/erb/mailer/templates/view.erb
deleted file mode 100644
index fcce7bd805..0000000000
--- a/railties/lib/generators/erb/mailer/templates/view.erb
+++ /dev/null
@@ -1,3 +0,0 @@
-<%= class_name %>#<%= @action %>
-
-Find me in app/views/<%= @path %>
diff --git a/railties/lib/generators/erb/mailer/templates/view.text.erb b/railties/lib/generators/erb/mailer/templates/view.text.erb
new file mode 100644
index 0000000000..6d597256a6
--- /dev/null
+++ b/railties/lib/generators/erb/mailer/templates/view.text.erb
@@ -0,0 +1,3 @@
+<%= class_name %>#<%= @action %>
+
+<%%= @greeting %>, find me in app/views/<%= @path %>
diff --git a/railties/lib/generators/rails/app/templates/Rakefile b/railties/lib/generators/rails/app/templates/Rakefile
index c19ad0e945..9cb2046439 100755
--- a/railties/lib/generators/rails/app/templates/Rakefile
+++ b/railties/lib/generators/rails/app/templates/Rakefile
@@ -7,4 +7,4 @@ require 'rake'
require 'rake/testtask'
require 'rake/rdoctask'
-<%= app_const %>.load_tasks
+Rails::Application.load_tasks
diff --git a/railties/lib/generators/rails/app/templates/config/boot.rb b/railties/lib/generators/rails/app/templates/config/boot.rb
index 466e1e50ec..7fc1aeaeb8 100644
--- a/railties/lib/generators/rails/app/templates/config/boot.rb
+++ b/railties/lib/generators/rails/app/templates/config/boot.rb
@@ -19,18 +19,22 @@ require 'rails/all'
# To pick the frameworks you want, remove 'require "rails/all"'
# and list the framework railties that you want:
#
+# require "active_support/railtie"
# require "active_model/railtie"
# require "active_record/railtie"
# require "action_controller/railtie"
# require "action_view/railtie"
# require "action_mailer/railtie"
# require "active_resource/railtie"
+# require "rails/test_unit/railtie"
<% else -%>
# Pick the frameworks you want:
+# require "active_model/railtie"
# require "active_record/railtie"
-require "active_model/railtie"
+require "active_support/railtie"
require "action_controller/railtie"
require "action_view/railtie"
require "action_mailer/railtie"
require "active_resource/railtie"
+require "rails/test_unit/railtie"
<% end -%> \ No newline at end of file
diff --git a/railties/lib/generators/rails/app/templates/public/javascripts/jquery-1.4.1.min.js b/railties/lib/generators/rails/app/templates/public/javascripts/jquery-1.4.1.min.js
new file mode 100644
index 0000000000..0c7294c90a
--- /dev/null
+++ b/railties/lib/generators/rails/app/templates/public/javascripts/jquery-1.4.1.min.js
@@ -0,0 +1,152 @@
+/*!
+ * jQuery JavaScript Library v1.4.1
+ * http://jquery.com/
+ *
+ * Copyright 2010, John Resig
+ * Dual licensed under the MIT or GPL Version 2 licenses.
+ * http://jquery.org/license
+ *
+ * Includes Sizzle.js
+ * http://sizzlejs.com/
+ * Copyright 2010, The Dojo Foundation
+ * Released under the MIT, BSD, and GPL Licenses.
+ *
+ * Date: Mon Jan 25 19:43:33 2010 -0500
+ */
+(function(z,v){function la(){if(!c.isReady){try{r.documentElement.doScroll("left")}catch(a){setTimeout(la,1);return}c.ready()}}function Ma(a,b){b.src?c.ajax({url:b.src,async:false,dataType:"script"}):c.globalEval(b.text||b.textContent||b.innerHTML||"");b.parentNode&&b.parentNode.removeChild(b)}function X(a,b,d,f,e,i){var j=a.length;if(typeof b==="object"){for(var n in b)X(a,n,b[n],f,e,d);return a}if(d!==v){f=!i&&f&&c.isFunction(d);for(n=0;n<j;n++)e(a[n],b,f?d.call(a[n],n,e(a[n],b)):d,i);return a}return j?
+e(a[0],b):null}function J(){return(new Date).getTime()}function Y(){return false}function Z(){return true}function ma(a,b,d){d[0].type=a;return c.event.handle.apply(b,d)}function na(a){var b,d=[],f=[],e=arguments,i,j,n,o,m,s,x=c.extend({},c.data(this,"events").live);if(!(a.button&&a.type==="click")){for(o in x){j=x[o];if(j.live===a.type||j.altLive&&c.inArray(a.type,j.altLive)>-1){i=j.data;i.beforeFilter&&i.beforeFilter[a.type]&&!i.beforeFilter[a.type](a)||f.push(j.selector)}else delete x[o]}i=c(a.target).closest(f,
+a.currentTarget);m=0;for(s=i.length;m<s;m++)for(o in x){j=x[o];n=i[m].elem;f=null;if(i[m].selector===j.selector){if(j.live==="mouseenter"||j.live==="mouseleave")f=c(a.relatedTarget).closest(j.selector)[0];if(!f||f!==n)d.push({elem:n,fn:j})}}m=0;for(s=d.length;m<s;m++){i=d[m];a.currentTarget=i.elem;a.data=i.fn.data;if(i.fn.apply(i.elem,e)===false){b=false;break}}return b}}function oa(a,b){return"live."+(a?a+".":"")+b.replace(/\./g,"`").replace(/ /g,"&")}function pa(a){return!a||!a.parentNode||a.parentNode.nodeType===
+11}function qa(a,b){var d=0;b.each(function(){if(this.nodeName===(a[d]&&a[d].nodeName)){var f=c.data(a[d++]),e=c.data(this,f);if(f=f&&f.events){delete e.handle;e.events={};for(var i in f)for(var j in f[i])c.event.add(this,i,f[i][j],f[i][j].data)}}})}function ra(a,b,d){var f,e,i;if(a.length===1&&typeof a[0]==="string"&&a[0].length<512&&a[0].indexOf("<option")<0&&(c.support.checkClone||!sa.test(a[0]))){e=true;if(i=c.fragments[a[0]])if(i!==1)f=i}if(!f){b=b&&b[0]?b[0].ownerDocument||b[0]:r;f=b.createDocumentFragment();
+c.clean(a,b,f,d)}if(e)c.fragments[a[0]]=i?f:1;return{fragment:f,cacheable:e}}function K(a,b){var d={};c.each(ta.concat.apply([],ta.slice(0,b)),function(){d[this]=a});return d}function ua(a){return"scrollTo"in a&&a.document?a:a.nodeType===9?a.defaultView||a.parentWindow:false}var c=function(a,b){return new c.fn.init(a,b)},Na=z.jQuery,Oa=z.$,r=z.document,S,Pa=/^[^<]*(<[\w\W]+>)[^>]*$|^#([\w-]+)$/,Qa=/^.[^:#\[\.,]*$/,Ra=/\S/,Sa=/^(\s|\u00A0)+|(\s|\u00A0)+$/g,Ta=/^<(\w+)\s*\/?>(?:<\/\1>)?$/,O=navigator.userAgent,
+va=false,P=[],L,$=Object.prototype.toString,aa=Object.prototype.hasOwnProperty,ba=Array.prototype.push,Q=Array.prototype.slice,wa=Array.prototype.indexOf;c.fn=c.prototype={init:function(a,b){var d,f;if(!a)return this;if(a.nodeType){this.context=this[0]=a;this.length=1;return this}if(typeof a==="string")if((d=Pa.exec(a))&&(d[1]||!b))if(d[1]){f=b?b.ownerDocument||b:r;if(a=Ta.exec(a))if(c.isPlainObject(b)){a=[r.createElement(a[1])];c.fn.attr.call(a,b,true)}else a=[f.createElement(a[1])];else{a=ra([d[1]],
+[f]);a=(a.cacheable?a.fragment.cloneNode(true):a.fragment).childNodes}}else{if(b=r.getElementById(d[2])){if(b.id!==d[2])return S.find(a);this.length=1;this[0]=b}this.context=r;this.selector=a;return this}else if(!b&&/^\w+$/.test(a)){this.selector=a;this.context=r;a=r.getElementsByTagName(a)}else return!b||b.jquery?(b||S).find(a):c(b).find(a);else if(c.isFunction(a))return S.ready(a);if(a.selector!==v){this.selector=a.selector;this.context=a.context}return c.isArray(a)?this.setArray(a):c.makeArray(a,
+this)},selector:"",jquery:"1.4.1",length:0,size:function(){return this.length},toArray:function(){return Q.call(this,0)},get:function(a){return a==null?this.toArray():a<0?this.slice(a)[0]:this[a]},pushStack:function(a,b,d){a=c(a||null);a.prevObject=this;a.context=this.context;if(b==="find")a.selector=this.selector+(this.selector?" ":"")+d;else if(b)a.selector=this.selector+"."+b+"("+d+")";return a},setArray:function(a){this.length=0;ba.apply(this,a);return this},each:function(a,b){return c.each(this,
+a,b)},ready:function(a){c.bindReady();if(c.isReady)a.call(r,c);else P&&P.push(a);return this},eq:function(a){return a===-1?this.slice(a):this.slice(a,+a+1)},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},slice:function(){return this.pushStack(Q.apply(this,arguments),"slice",Q.call(arguments).join(","))},map:function(a){return this.pushStack(c.map(this,function(b,d){return a.call(b,d,b)}))},end:function(){return this.prevObject||c(null)},push:ba,sort:[].sort,splice:[].splice};
+c.fn.init.prototype=c.fn;c.extend=c.fn.extend=function(){var a=arguments[0]||{},b=1,d=arguments.length,f=false,e,i,j,n;if(typeof a==="boolean"){f=a;a=arguments[1]||{};b=2}if(typeof a!=="object"&&!c.isFunction(a))a={};if(d===b){a=this;--b}for(;b<d;b++)if((e=arguments[b])!=null)for(i in e){j=a[i];n=e[i];if(a!==n)if(f&&n&&(c.isPlainObject(n)||c.isArray(n))){j=j&&(c.isPlainObject(j)||c.isArray(j))?j:c.isArray(n)?[]:{};a[i]=c.extend(f,j,n)}else if(n!==v)a[i]=n}return a};c.extend({noConflict:function(a){z.$=
+Oa;if(a)z.jQuery=Na;return c},isReady:false,ready:function(){if(!c.isReady){if(!r.body)return setTimeout(c.ready,13);c.isReady=true;if(P){for(var a,b=0;a=P[b++];)a.call(r,c);P=null}c.fn.triggerHandler&&c(r).triggerHandler("ready")}},bindReady:function(){if(!va){va=true;if(r.readyState==="complete")return c.ready();if(r.addEventListener){r.addEventListener("DOMContentLoaded",L,false);z.addEventListener("load",c.ready,false)}else if(r.attachEvent){r.attachEvent("onreadystatechange",L);z.attachEvent("onload",
+c.ready);var a=false;try{a=z.frameElement==null}catch(b){}r.documentElement.doScroll&&a&&la()}}},isFunction:function(a){return $.call(a)==="[object Function]"},isArray:function(a){return $.call(a)==="[object Array]"},isPlainObject:function(a){if(!a||$.call(a)!=="[object Object]"||a.nodeType||a.setInterval)return false;if(a.constructor&&!aa.call(a,"constructor")&&!aa.call(a.constructor.prototype,"isPrototypeOf"))return false;var b;for(b in a);return b===v||aa.call(a,b)},isEmptyObject:function(a){for(var b in a)return false;
+return true},error:function(a){throw a;},parseJSON:function(a){if(typeof a!=="string"||!a)return null;if(/^[\],:{}\s]*$/.test(a.replace(/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,"@").replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,"]").replace(/(?:^|:|,)(?:\s*\[)+/g,"")))return z.JSON&&z.JSON.parse?z.JSON.parse(a):(new Function("return "+a))();else c.error("Invalid JSON: "+a)},noop:function(){},globalEval:function(a){if(a&&Ra.test(a)){var b=r.getElementsByTagName("head")[0]||
+r.documentElement,d=r.createElement("script");d.type="text/javascript";if(c.support.scriptEval)d.appendChild(r.createTextNode(a));else d.text=a;b.insertBefore(d,b.firstChild);b.removeChild(d)}},nodeName:function(a,b){return a.nodeName&&a.nodeName.toUpperCase()===b.toUpperCase()},each:function(a,b,d){var f,e=0,i=a.length,j=i===v||c.isFunction(a);if(d)if(j)for(f in a){if(b.apply(a[f],d)===false)break}else for(;e<i;){if(b.apply(a[e++],d)===false)break}else if(j)for(f in a){if(b.call(a[f],f,a[f])===false)break}else for(d=
+a[0];e<i&&b.call(d,e,d)!==false;d=a[++e]);return a},trim:function(a){return(a||"").replace(Sa,"")},makeArray:function(a,b){b=b||[];if(a!=null)a.length==null||typeof a==="string"||c.isFunction(a)||typeof a!=="function"&&a.setInterval?ba.call(b,a):c.merge(b,a);return b},inArray:function(a,b){if(b.indexOf)return b.indexOf(a);for(var d=0,f=b.length;d<f;d++)if(b[d]===a)return d;return-1},merge:function(a,b){var d=a.length,f=0;if(typeof b.length==="number")for(var e=b.length;f<e;f++)a[d++]=b[f];else for(;b[f]!==
+v;)a[d++]=b[f++];a.length=d;return a},grep:function(a,b,d){for(var f=[],e=0,i=a.length;e<i;e++)!d!==!b(a[e],e)&&f.push(a[e]);return f},map:function(a,b,d){for(var f=[],e,i=0,j=a.length;i<j;i++){e=b(a[i],i,d);if(e!=null)f[f.length]=e}return f.concat.apply([],f)},guid:1,proxy:function(a,b,d){if(arguments.length===2)if(typeof b==="string"){d=a;a=d[b];b=v}else if(b&&!c.isFunction(b)){d=b;b=v}if(!b&&a)b=function(){return a.apply(d||this,arguments)};if(a)b.guid=a.guid=a.guid||b.guid||c.guid++;return b},
+uaMatch:function(a){a=a.toLowerCase();a=/(webkit)[ \/]([\w.]+)/.exec(a)||/(opera)(?:.*version)?[ \/]([\w.]+)/.exec(a)||/(msie) ([\w.]+)/.exec(a)||!/compatible/.test(a)&&/(mozilla)(?:.*? rv:([\w.]+))?/.exec(a)||[];return{browser:a[1]||"",version:a[2]||"0"}},browser:{}});O=c.uaMatch(O);if(O.browser){c.browser[O.browser]=true;c.browser.version=O.version}if(c.browser.webkit)c.browser.safari=true;if(wa)c.inArray=function(a,b){return wa.call(b,a)};S=c(r);if(r.addEventListener)L=function(){r.removeEventListener("DOMContentLoaded",
+L,false);c.ready()};else if(r.attachEvent)L=function(){if(r.readyState==="complete"){r.detachEvent("onreadystatechange",L);c.ready()}};(function(){c.support={};var a=r.documentElement,b=r.createElement("script"),d=r.createElement("div"),f="script"+J();d.style.display="none";d.innerHTML=" <link/><table></table><a href='/a' style='color:red;float:left;opacity:.55;'>a</a><input type='checkbox'/>";var e=d.getElementsByTagName("*"),i=d.getElementsByTagName("a")[0];if(!(!e||!e.length||!i)){c.support=
+{leadingWhitespace:d.firstChild.nodeType===3,tbody:!d.getElementsByTagName("tbody").length,htmlSerialize:!!d.getElementsByTagName("link").length,style:/red/.test(i.getAttribute("style")),hrefNormalized:i.getAttribute("href")==="/a",opacity:/^0.55$/.test(i.style.opacity),cssFloat:!!i.style.cssFloat,checkOn:d.getElementsByTagName("input")[0].value==="on",optSelected:r.createElement("select").appendChild(r.createElement("option")).selected,checkClone:false,scriptEval:false,noCloneEvent:true,boxModel:null};
+b.type="text/javascript";try{b.appendChild(r.createTextNode("window."+f+"=1;"))}catch(j){}a.insertBefore(b,a.firstChild);if(z[f]){c.support.scriptEval=true;delete z[f]}a.removeChild(b);if(d.attachEvent&&d.fireEvent){d.attachEvent("onclick",function n(){c.support.noCloneEvent=false;d.detachEvent("onclick",n)});d.cloneNode(true).fireEvent("onclick")}d=r.createElement("div");d.innerHTML="<input type='radio' name='radiotest' checked='checked'/>";a=r.createDocumentFragment();a.appendChild(d.firstChild);
+c.support.checkClone=a.cloneNode(true).cloneNode(true).lastChild.checked;c(function(){var n=r.createElement("div");n.style.width=n.style.paddingLeft="1px";r.body.appendChild(n);c.boxModel=c.support.boxModel=n.offsetWidth===2;r.body.removeChild(n).style.display="none"});a=function(n){var o=r.createElement("div");n="on"+n;var m=n in o;if(!m){o.setAttribute(n,"return;");m=typeof o[n]==="function"}return m};c.support.submitBubbles=a("submit");c.support.changeBubbles=a("change");a=b=d=e=i=null}})();c.props=
+{"for":"htmlFor","class":"className",readonly:"readOnly",maxlength:"maxLength",cellspacing:"cellSpacing",rowspan:"rowSpan",colspan:"colSpan",tabindex:"tabIndex",usemap:"useMap",frameborder:"frameBorder"};var G="jQuery"+J(),Ua=0,xa={},Va={};c.extend({cache:{},expando:G,noData:{embed:true,object:true,applet:true},data:function(a,b,d){if(!(a.nodeName&&c.noData[a.nodeName.toLowerCase()])){a=a==z?xa:a;var f=a[G],e=c.cache;if(!b&&!f)return null;f||(f=++Ua);if(typeof b==="object"){a[G]=f;e=e[f]=c.extend(true,
+{},b)}else e=e[f]?e[f]:typeof d==="undefined"?Va:(e[f]={});if(d!==v){a[G]=f;e[b]=d}return typeof b==="string"?e[b]:e}},removeData:function(a,b){if(!(a.nodeName&&c.noData[a.nodeName.toLowerCase()])){a=a==z?xa:a;var d=a[G],f=c.cache,e=f[d];if(b){if(e){delete e[b];c.isEmptyObject(e)&&c.removeData(a)}}else{try{delete a[G]}catch(i){a.removeAttribute&&a.removeAttribute(G)}delete f[d]}}}});c.fn.extend({data:function(a,b){if(typeof a==="undefined"&&this.length)return c.data(this[0]);else if(typeof a==="object")return this.each(function(){c.data(this,
+a)});var d=a.split(".");d[1]=d[1]?"."+d[1]:"";if(b===v){var f=this.triggerHandler("getData"+d[1]+"!",[d[0]]);if(f===v&&this.length)f=c.data(this[0],a);return f===v&&d[1]?this.data(d[0]):f}else return this.trigger("setData"+d[1]+"!",[d[0],b]).each(function(){c.data(this,a,b)})},removeData:function(a){return this.each(function(){c.removeData(this,a)})}});c.extend({queue:function(a,b,d){if(a){b=(b||"fx")+"queue";var f=c.data(a,b);if(!d)return f||[];if(!f||c.isArray(d))f=c.data(a,b,c.makeArray(d));else f.push(d);
+return f}},dequeue:function(a,b){b=b||"fx";var d=c.queue(a,b),f=d.shift();if(f==="inprogress")f=d.shift();if(f){b==="fx"&&d.unshift("inprogress");f.call(a,function(){c.dequeue(a,b)})}}});c.fn.extend({queue:function(a,b){if(typeof a!=="string"){b=a;a="fx"}if(b===v)return c.queue(this[0],a);return this.each(function(){var d=c.queue(this,a,b);a==="fx"&&d[0]!=="inprogress"&&c.dequeue(this,a)})},dequeue:function(a){return this.each(function(){c.dequeue(this,a)})},delay:function(a,b){a=c.fx?c.fx.speeds[a]||
+a:a;b=b||"fx";return this.queue(b,function(){var d=this;setTimeout(function(){c.dequeue(d,b)},a)})},clearQueue:function(a){return this.queue(a||"fx",[])}});var ya=/[\n\t]/g,ca=/\s+/,Wa=/\r/g,Xa=/href|src|style/,Ya=/(button|input)/i,Za=/(button|input|object|select|textarea)/i,$a=/^(a|area)$/i,za=/radio|checkbox/;c.fn.extend({attr:function(a,b){return X(this,a,b,true,c.attr)},removeAttr:function(a){return this.each(function(){c.attr(this,a,"");this.nodeType===1&&this.removeAttribute(a)})},addClass:function(a){if(c.isFunction(a))return this.each(function(o){var m=
+c(this);m.addClass(a.call(this,o,m.attr("class")))});if(a&&typeof a==="string")for(var b=(a||"").split(ca),d=0,f=this.length;d<f;d++){var e=this[d];if(e.nodeType===1)if(e.className)for(var i=" "+e.className+" ",j=0,n=b.length;j<n;j++){if(i.indexOf(" "+b[j]+" ")<0)e.className+=" "+b[j]}else e.className=a}return this},removeClass:function(a){if(c.isFunction(a))return this.each(function(o){var m=c(this);m.removeClass(a.call(this,o,m.attr("class")))});if(a&&typeof a==="string"||a===v)for(var b=(a||"").split(ca),
+d=0,f=this.length;d<f;d++){var e=this[d];if(e.nodeType===1&&e.className)if(a){for(var i=(" "+e.className+" ").replace(ya," "),j=0,n=b.length;j<n;j++)i=i.replace(" "+b[j]+" "," ");e.className=i.substring(1,i.length-1)}else e.className=""}return this},toggleClass:function(a,b){var d=typeof a,f=typeof b==="boolean";if(c.isFunction(a))return this.each(function(e){var i=c(this);i.toggleClass(a.call(this,e,i.attr("class"),b),b)});return this.each(function(){if(d==="string")for(var e,i=0,j=c(this),n=b,o=
+a.split(ca);e=o[i++];){n=f?n:!j.hasClass(e);j[n?"addClass":"removeClass"](e)}else if(d==="undefined"||d==="boolean"){this.className&&c.data(this,"__className__",this.className);this.className=this.className||a===false?"":c.data(this,"__className__")||""}})},hasClass:function(a){a=" "+a+" ";for(var b=0,d=this.length;b<d;b++)if((" "+this[b].className+" ").replace(ya," ").indexOf(a)>-1)return true;return false},val:function(a){if(a===v){var b=this[0];if(b){if(c.nodeName(b,"option"))return(b.attributes.value||
+{}).specified?b.value:b.text;if(c.nodeName(b,"select")){var d=b.selectedIndex,f=[],e=b.options;b=b.type==="select-one";if(d<0)return null;var i=b?d:0;for(d=b?d+1:e.length;i<d;i++){var j=e[i];if(j.selected){a=c(j).val();if(b)return a;f.push(a)}}return f}if(za.test(b.type)&&!c.support.checkOn)return b.getAttribute("value")===null?"on":b.value;return(b.value||"").replace(Wa,"")}return v}var n=c.isFunction(a);return this.each(function(o){var m=c(this),s=a;if(this.nodeType===1){if(n)s=a.call(this,o,m.val());
+if(typeof s==="number")s+="";if(c.isArray(s)&&za.test(this.type))this.checked=c.inArray(m.val(),s)>=0;else if(c.nodeName(this,"select")){var x=c.makeArray(s);c("option",this).each(function(){this.selected=c.inArray(c(this).val(),x)>=0});if(!x.length)this.selectedIndex=-1}else this.value=s}})}});c.extend({attrFn:{val:true,css:true,html:true,text:true,data:true,width:true,height:true,offset:true},attr:function(a,b,d,f){if(!a||a.nodeType===3||a.nodeType===8)return v;if(f&&b in c.attrFn)return c(a)[b](d);
+f=a.nodeType!==1||!c.isXMLDoc(a);var e=d!==v;b=f&&c.props[b]||b;if(a.nodeType===1){var i=Xa.test(b);if(b in a&&f&&!i){if(e){b==="type"&&Ya.test(a.nodeName)&&a.parentNode&&c.error("type property can't be changed");a[b]=d}if(c.nodeName(a,"form")&&a.getAttributeNode(b))return a.getAttributeNode(b).nodeValue;if(b==="tabIndex")return(b=a.getAttributeNode("tabIndex"))&&b.specified?b.value:Za.test(a.nodeName)||$a.test(a.nodeName)&&a.href?0:v;return a[b]}if(!c.support.style&&f&&b==="style"){if(e)a.style.cssText=
+""+d;return a.style.cssText}e&&a.setAttribute(b,""+d);a=!c.support.hrefNormalized&&f&&i?a.getAttribute(b,2):a.getAttribute(b);return a===null?v:a}return c.style(a,b,d)}});var ab=function(a){return a.replace(/[^\w\s\.\|`]/g,function(b){return"\\"+b})};c.event={add:function(a,b,d,f){if(!(a.nodeType===3||a.nodeType===8)){if(a.setInterval&&a!==z&&!a.frameElement)a=z;if(!d.guid)d.guid=c.guid++;if(f!==v){d=c.proxy(d);d.data=f}var e=c.data(a,"events")||c.data(a,"events",{}),i=c.data(a,"handle"),j;if(!i){j=
+function(){return typeof c!=="undefined"&&!c.event.triggered?c.event.handle.apply(j.elem,arguments):v};i=c.data(a,"handle",j)}if(i){i.elem=a;b=b.split(/\s+/);for(var n,o=0;n=b[o++];){var m=n.split(".");n=m.shift();if(o>1){d=c.proxy(d);if(f!==v)d.data=f}d.type=m.slice(0).sort().join(".");var s=e[n],x=this.special[n]||{};if(!s){s=e[n]={};if(!x.setup||x.setup.call(a,f,m,d)===false)if(a.addEventListener)a.addEventListener(n,i,false);else a.attachEvent&&a.attachEvent("on"+n,i)}if(x.add)if((m=x.add.call(a,
+d,f,m,s))&&c.isFunction(m)){m.guid=m.guid||d.guid;m.data=m.data||d.data;m.type=m.type||d.type;d=m}s[d.guid]=d;this.global[n]=true}a=null}}},global:{},remove:function(a,b,d){if(!(a.nodeType===3||a.nodeType===8)){var f=c.data(a,"events"),e,i,j;if(f){if(b===v||typeof b==="string"&&b.charAt(0)===".")for(i in f)this.remove(a,i+(b||""));else{if(b.type){d=b.handler;b=b.type}b=b.split(/\s+/);for(var n=0;i=b[n++];){var o=i.split(".");i=o.shift();var m=!o.length,s=c.map(o.slice(0).sort(),ab);s=new RegExp("(^|\\.)"+
+s.join("\\.(?:.*\\.)?")+"(\\.|$)");var x=this.special[i]||{};if(f[i]){if(d){j=f[i][d.guid];delete f[i][d.guid]}else for(var A in f[i])if(m||s.test(f[i][A].type))delete f[i][A];x.remove&&x.remove.call(a,o,j);for(e in f[i])break;if(!e){if(!x.teardown||x.teardown.call(a,o)===false)if(a.removeEventListener)a.removeEventListener(i,c.data(a,"handle"),false);else a.detachEvent&&a.detachEvent("on"+i,c.data(a,"handle"));e=null;delete f[i]}}}}for(e in f)break;if(!e){if(A=c.data(a,"handle"))A.elem=null;c.removeData(a,
+"events");c.removeData(a,"handle")}}}},trigger:function(a,b,d,f){var e=a.type||a;if(!f){a=typeof a==="object"?a[G]?a:c.extend(c.Event(e),a):c.Event(e);if(e.indexOf("!")>=0){a.type=e=e.slice(0,-1);a.exclusive=true}if(!d){a.stopPropagation();this.global[e]&&c.each(c.cache,function(){this.events&&this.events[e]&&c.event.trigger(a,b,this.handle.elem)})}if(!d||d.nodeType===3||d.nodeType===8)return v;a.result=v;a.target=d;b=c.makeArray(b);b.unshift(a)}a.currentTarget=d;(f=c.data(d,"handle"))&&f.apply(d,
+b);f=d.parentNode||d.ownerDocument;try{if(!(d&&d.nodeName&&c.noData[d.nodeName.toLowerCase()]))if(d["on"+e]&&d["on"+e].apply(d,b)===false)a.result=false}catch(i){}if(!a.isPropagationStopped()&&f)c.event.trigger(a,b,f,true);else if(!a.isDefaultPrevented()){d=a.target;var j;if(!(c.nodeName(d,"a")&&e==="click")&&!(d&&d.nodeName&&c.noData[d.nodeName.toLowerCase()])){try{if(d[e]){if(j=d["on"+e])d["on"+e]=null;this.triggered=true;d[e]()}}catch(n){}if(j)d["on"+e]=j;this.triggered=false}}},handle:function(a){var b,
+d;a=arguments[0]=c.event.fix(a||z.event);a.currentTarget=this;d=a.type.split(".");a.type=d.shift();b=!d.length&&!a.exclusive;var f=new RegExp("(^|\\.)"+d.slice(0).sort().join("\\.(?:.*\\.)?")+"(\\.|$)");d=(c.data(this,"events")||{})[a.type];for(var e in d){var i=d[e];if(b||f.test(i.type)){a.handler=i;a.data=i.data;i=i.apply(this,arguments);if(i!==v){a.result=i;if(i===false){a.preventDefault();a.stopPropagation()}}if(a.isImmediatePropagationStopped())break}}return a.result},props:"altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode layerX layerY metaKey newValue offsetX offsetY originalTarget pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target toElement view wheelDelta which".split(" "),
+fix:function(a){if(a[G])return a;var b=a;a=c.Event(b);for(var d=this.props.length,f;d;){f=this.props[--d];a[f]=b[f]}if(!a.target)a.target=a.srcElement||r;if(a.target.nodeType===3)a.target=a.target.parentNode;if(!a.relatedTarget&&a.fromElement)a.relatedTarget=a.fromElement===a.target?a.toElement:a.fromElement;if(a.pageX==null&&a.clientX!=null){b=r.documentElement;d=r.body;a.pageX=a.clientX+(b&&b.scrollLeft||d&&d.scrollLeft||0)-(b&&b.clientLeft||d&&d.clientLeft||0);a.pageY=a.clientY+(b&&b.scrollTop||
+d&&d.scrollTop||0)-(b&&b.clientTop||d&&d.clientTop||0)}if(!a.which&&(a.charCode||a.charCode===0?a.charCode:a.keyCode))a.which=a.charCode||a.keyCode;if(!a.metaKey&&a.ctrlKey)a.metaKey=a.ctrlKey;if(!a.which&&a.button!==v)a.which=a.button&1?1:a.button&2?3:a.button&4?2:0;return a},guid:1E8,proxy:c.proxy,special:{ready:{setup:c.bindReady,teardown:c.noop},live:{add:function(a,b){c.extend(a,b||{});a.guid+=b.selector+b.live;b.liveProxy=a;c.event.add(this,b.live,na,b)},remove:function(a){if(a.length){var b=
+0,d=new RegExp("(^|\\.)"+a[0]+"(\\.|$)");c.each(c.data(this,"events").live||{},function(){d.test(this.type)&&b++});b<1&&c.event.remove(this,a[0],na)}},special:{}},beforeunload:{setup:function(a,b,d){if(this.setInterval)this.onbeforeunload=d;return false},teardown:function(a,b){if(this.onbeforeunload===b)this.onbeforeunload=null}}}};c.Event=function(a){if(!this.preventDefault)return new c.Event(a);if(a&&a.type){this.originalEvent=a;this.type=a.type}else this.type=a;this.timeStamp=J();this[G]=true};
+c.Event.prototype={preventDefault:function(){this.isDefaultPrevented=Z;var a=this.originalEvent;if(a){a.preventDefault&&a.preventDefault();a.returnValue=false}},stopPropagation:function(){this.isPropagationStopped=Z;var a=this.originalEvent;if(a){a.stopPropagation&&a.stopPropagation();a.cancelBubble=true}},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=Z;this.stopPropagation()},isDefaultPrevented:Y,isPropagationStopped:Y,isImmediatePropagationStopped:Y};var Aa=function(a){for(var b=
+a.relatedTarget;b&&b!==this;)try{b=b.parentNode}catch(d){break}if(b!==this){a.type=a.data;c.event.handle.apply(this,arguments)}},Ba=function(a){a.type=a.data;c.event.handle.apply(this,arguments)};c.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(a,b){c.event.special[a]={setup:function(d){c.event.add(this,b,d&&d.selector?Ba:Aa,a)},teardown:function(d){c.event.remove(this,b,d&&d.selector?Ba:Aa)}}});if(!c.support.submitBubbles)c.event.special.submit={setup:function(a,b,d){if(this.nodeName.toLowerCase()!==
+"form"){c.event.add(this,"click.specialSubmit."+d.guid,function(f){var e=f.target,i=e.type;if((i==="submit"||i==="image")&&c(e).closest("form").length)return ma("submit",this,arguments)});c.event.add(this,"keypress.specialSubmit."+d.guid,function(f){var e=f.target,i=e.type;if((i==="text"||i==="password")&&c(e).closest("form").length&&f.keyCode===13)return ma("submit",this,arguments)})}else return false},remove:function(a,b){c.event.remove(this,"click.specialSubmit"+(b?"."+b.guid:""));c.event.remove(this,
+"keypress.specialSubmit"+(b?"."+b.guid:""))}};if(!c.support.changeBubbles){var da=/textarea|input|select/i;function Ca(a){var b=a.type,d=a.value;if(b==="radio"||b==="checkbox")d=a.checked;else if(b==="select-multiple")d=a.selectedIndex>-1?c.map(a.options,function(f){return f.selected}).join("-"):"";else if(a.nodeName.toLowerCase()==="select")d=a.selectedIndex;return d}function ea(a,b){var d=a.target,f,e;if(!(!da.test(d.nodeName)||d.readOnly)){f=c.data(d,"_change_data");e=Ca(d);if(a.type!=="focusout"||
+d.type!=="radio")c.data(d,"_change_data",e);if(!(f===v||e===f))if(f!=null||e){a.type="change";return c.event.trigger(a,b,d)}}}c.event.special.change={filters:{focusout:ea,click:function(a){var b=a.target,d=b.type;if(d==="radio"||d==="checkbox"||b.nodeName.toLowerCase()==="select")return ea.call(this,a)},keydown:function(a){var b=a.target,d=b.type;if(a.keyCode===13&&b.nodeName.toLowerCase()!=="textarea"||a.keyCode===32&&(d==="checkbox"||d==="radio")||d==="select-multiple")return ea.call(this,a)},beforeactivate:function(a){a=
+a.target;a.nodeName.toLowerCase()==="input"&&a.type==="radio"&&c.data(a,"_change_data",Ca(a))}},setup:function(a,b,d){for(var f in T)c.event.add(this,f+".specialChange."+d.guid,T[f]);return da.test(this.nodeName)},remove:function(a,b){for(var d in T)c.event.remove(this,d+".specialChange"+(b?"."+b.guid:""),T[d]);return da.test(this.nodeName)}};var T=c.event.special.change.filters}r.addEventListener&&c.each({focus:"focusin",blur:"focusout"},function(a,b){function d(f){f=c.event.fix(f);f.type=b;return c.event.handle.call(this,
+f)}c.event.special[b]={setup:function(){this.addEventListener(a,d,true)},teardown:function(){this.removeEventListener(a,d,true)}}});c.each(["bind","one"],function(a,b){c.fn[b]=function(d,f,e){if(typeof d==="object"){for(var i in d)this[b](i,f,d[i],e);return this}if(c.isFunction(f)){e=f;f=v}var j=b==="one"?c.proxy(e,function(n){c(this).unbind(n,j);return e.apply(this,arguments)}):e;return d==="unload"&&b!=="one"?this.one(d,f,e):this.each(function(){c.event.add(this,d,j,f)})}});c.fn.extend({unbind:function(a,
+b){if(typeof a==="object"&&!a.preventDefault){for(var d in a)this.unbind(d,a[d]);return this}return this.each(function(){c.event.remove(this,a,b)})},trigger:function(a,b){return this.each(function(){c.event.trigger(a,b,this)})},triggerHandler:function(a,b){if(this[0]){a=c.Event(a);a.preventDefault();a.stopPropagation();c.event.trigger(a,b,this[0]);return a.result}},toggle:function(a){for(var b=arguments,d=1;d<b.length;)c.proxy(a,b[d++]);return this.click(c.proxy(a,function(f){var e=(c.data(this,"lastToggle"+
+a.guid)||0)%d;c.data(this,"lastToggle"+a.guid,e+1);f.preventDefault();return b[e].apply(this,arguments)||false}))},hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)}});c.each(["live","die"],function(a,b){c.fn[b]=function(d,f,e){var i,j=0;if(c.isFunction(f)){e=f;f=v}for(d=(d||"").split(/\s+/);(i=d[j++])!=null;){i=i==="focus"?"focusin":i==="blur"?"focusout":i==="hover"?d.push("mouseleave")&&"mouseenter":i;b==="live"?c(this.context).bind(oa(i,this.selector),{data:f,selector:this.selector,
+live:i},e):c(this.context).unbind(oa(i,this.selector),e?{guid:e.guid+this.selector+i}:null)}return this}});c.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error".split(" "),function(a,b){c.fn[b]=function(d){return d?this.bind(b,d):this.trigger(b)};if(c.attrFn)c.attrFn[b]=true});z.attachEvent&&!z.addEventListener&&z.attachEvent("onunload",function(){for(var a in c.cache)if(c.cache[a].handle)try{c.event.remove(c.cache[a].handle.elem)}catch(b){}});
+(function(){function a(g){for(var h="",k,l=0;g[l];l++){k=g[l];if(k.nodeType===3||k.nodeType===4)h+=k.nodeValue;else if(k.nodeType!==8)h+=a(k.childNodes)}return h}function b(g,h,k,l,q,p){q=0;for(var u=l.length;q<u;q++){var t=l[q];if(t){t=t[g];for(var y=false;t;){if(t.sizcache===k){y=l[t.sizset];break}if(t.nodeType===1&&!p){t.sizcache=k;t.sizset=q}if(t.nodeName.toLowerCase()===h){y=t;break}t=t[g]}l[q]=y}}}function d(g,h,k,l,q,p){q=0;for(var u=l.length;q<u;q++){var t=l[q];if(t){t=t[g];for(var y=false;t;){if(t.sizcache===
+k){y=l[t.sizset];break}if(t.nodeType===1){if(!p){t.sizcache=k;t.sizset=q}if(typeof h!=="string"){if(t===h){y=true;break}}else if(o.filter(h,[t]).length>0){y=t;break}}t=t[g]}l[q]=y}}}var f=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^[\]]*\]|['"][^'"]*['"]|[^[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,e=0,i=Object.prototype.toString,j=false,n=true;[0,0].sort(function(){n=false;return 0});var o=function(g,h,k,l){k=k||[];var q=h=h||r;if(h.nodeType!==1&&h.nodeType!==9)return[];if(!g||
+typeof g!=="string")return k;for(var p=[],u,t,y,R,H=true,M=w(h),I=g;(f.exec(""),u=f.exec(I))!==null;){I=u[3];p.push(u[1]);if(u[2]){R=u[3];break}}if(p.length>1&&s.exec(g))if(p.length===2&&m.relative[p[0]])t=fa(p[0]+p[1],h);else for(t=m.relative[p[0]]?[h]:o(p.shift(),h);p.length;){g=p.shift();if(m.relative[g])g+=p.shift();t=fa(g,t)}else{if(!l&&p.length>1&&h.nodeType===9&&!M&&m.match.ID.test(p[0])&&!m.match.ID.test(p[p.length-1])){u=o.find(p.shift(),h,M);h=u.expr?o.filter(u.expr,u.set)[0]:u.set[0]}if(h){u=
+l?{expr:p.pop(),set:A(l)}:o.find(p.pop(),p.length===1&&(p[0]==="~"||p[0]==="+")&&h.parentNode?h.parentNode:h,M);t=u.expr?o.filter(u.expr,u.set):u.set;if(p.length>0)y=A(t);else H=false;for(;p.length;){var D=p.pop();u=D;if(m.relative[D])u=p.pop();else D="";if(u==null)u=h;m.relative[D](y,u,M)}}else y=[]}y||(y=t);y||o.error(D||g);if(i.call(y)==="[object Array]")if(H)if(h&&h.nodeType===1)for(g=0;y[g]!=null;g++){if(y[g]&&(y[g]===true||y[g].nodeType===1&&E(h,y[g])))k.push(t[g])}else for(g=0;y[g]!=null;g++)y[g]&&
+y[g].nodeType===1&&k.push(t[g]);else k.push.apply(k,y);else A(y,k);if(R){o(R,q,k,l);o.uniqueSort(k)}return k};o.uniqueSort=function(g){if(C){j=n;g.sort(C);if(j)for(var h=1;h<g.length;h++)g[h]===g[h-1]&&g.splice(h--,1)}return g};o.matches=function(g,h){return o(g,null,null,h)};o.find=function(g,h,k){var l,q;if(!g)return[];for(var p=0,u=m.order.length;p<u;p++){var t=m.order[p];if(q=m.leftMatch[t].exec(g)){var y=q[1];q.splice(1,1);if(y.substr(y.length-1)!=="\\"){q[1]=(q[1]||"").replace(/\\/g,"");l=m.find[t](q,
+h,k);if(l!=null){g=g.replace(m.match[t],"");break}}}}l||(l=h.getElementsByTagName("*"));return{set:l,expr:g}};o.filter=function(g,h,k,l){for(var q=g,p=[],u=h,t,y,R=h&&h[0]&&w(h[0]);g&&h.length;){for(var H in m.filter)if((t=m.leftMatch[H].exec(g))!=null&&t[2]){var M=m.filter[H],I,D;D=t[1];y=false;t.splice(1,1);if(D.substr(D.length-1)!=="\\"){if(u===p)p=[];if(m.preFilter[H])if(t=m.preFilter[H](t,u,k,p,l,R)){if(t===true)continue}else y=I=true;if(t)for(var U=0;(D=u[U])!=null;U++)if(D){I=M(D,t,U,u);var Da=
+l^!!I;if(k&&I!=null)if(Da)y=true;else u[U]=false;else if(Da){p.push(D);y=true}}if(I!==v){k||(u=p);g=g.replace(m.match[H],"");if(!y)return[];break}}}if(g===q)if(y==null)o.error(g);else break;q=g}return u};o.error=function(g){throw"Syntax error, unrecognized expression: "+g;};var m=o.selectors={order:["ID","NAME","TAG"],match:{ID:/#((?:[\w\u00c0-\uFFFF-]|\\.)+)/,CLASS:/\.((?:[\w\u00c0-\uFFFF-]|\\.)+)/,NAME:/\[name=['"]*((?:[\w\u00c0-\uFFFF-]|\\.)+)['"]*\]/,ATTR:/\[\s*((?:[\w\u00c0-\uFFFF-]|\\.)+)\s*(?:(\S?=)\s*(['"]*)(.*?)\3|)\s*\]/,
+TAG:/^((?:[\w\u00c0-\uFFFF\*-]|\\.)+)/,CHILD:/:(only|nth|last|first)-child(?:\((even|odd|[\dn+-]*)\))?/,POS:/:(nth|eq|gt|lt|first|last|even|odd)(?:\((\d*)\))?(?=[^-]|$)/,PSEUDO:/:((?:[\w\u00c0-\uFFFF-]|\\.)+)(?:\((['"]?)((?:\([^\)]+\)|[^\(\)]*)+)\2\))?/},leftMatch:{},attrMap:{"class":"className","for":"htmlFor"},attrHandle:{href:function(g){return g.getAttribute("href")}},relative:{"+":function(g,h){var k=typeof h==="string",l=k&&!/\W/.test(h);k=k&&!l;if(l)h=h.toLowerCase();l=0;for(var q=g.length,
+p;l<q;l++)if(p=g[l]){for(;(p=p.previousSibling)&&p.nodeType!==1;);g[l]=k||p&&p.nodeName.toLowerCase()===h?p||false:p===h}k&&o.filter(h,g,true)},">":function(g,h){var k=typeof h==="string";if(k&&!/\W/.test(h)){h=h.toLowerCase();for(var l=0,q=g.length;l<q;l++){var p=g[l];if(p){k=p.parentNode;g[l]=k.nodeName.toLowerCase()===h?k:false}}}else{l=0;for(q=g.length;l<q;l++)if(p=g[l])g[l]=k?p.parentNode:p.parentNode===h;k&&o.filter(h,g,true)}},"":function(g,h,k){var l=e++,q=d;if(typeof h==="string"&&!/\W/.test(h)){var p=
+h=h.toLowerCase();q=b}q("parentNode",h,l,g,p,k)},"~":function(g,h,k){var l=e++,q=d;if(typeof h==="string"&&!/\W/.test(h)){var p=h=h.toLowerCase();q=b}q("previousSibling",h,l,g,p,k)}},find:{ID:function(g,h,k){if(typeof h.getElementById!=="undefined"&&!k)return(g=h.getElementById(g[1]))?[g]:[]},NAME:function(g,h){if(typeof h.getElementsByName!=="undefined"){var k=[];h=h.getElementsByName(g[1]);for(var l=0,q=h.length;l<q;l++)h[l].getAttribute("name")===g[1]&&k.push(h[l]);return k.length===0?null:k}},
+TAG:function(g,h){return h.getElementsByTagName(g[1])}},preFilter:{CLASS:function(g,h,k,l,q,p){g=" "+g[1].replace(/\\/g,"")+" ";if(p)return g;p=0;for(var u;(u=h[p])!=null;p++)if(u)if(q^(u.className&&(" "+u.className+" ").replace(/[\t\n]/g," ").indexOf(g)>=0))k||l.push(u);else if(k)h[p]=false;return false},ID:function(g){return g[1].replace(/\\/g,"")},TAG:function(g){return g[1].toLowerCase()},CHILD:function(g){if(g[1]==="nth"){var h=/(-?)(\d*)n((?:\+|-)?\d*)/.exec(g[2]==="even"&&"2n"||g[2]==="odd"&&
+"2n+1"||!/\D/.test(g[2])&&"0n+"+g[2]||g[2]);g[2]=h[1]+(h[2]||1)-0;g[3]=h[3]-0}g[0]=e++;return g},ATTR:function(g,h,k,l,q,p){h=g[1].replace(/\\/g,"");if(!p&&m.attrMap[h])g[1]=m.attrMap[h];if(g[2]==="~=")g[4]=" "+g[4]+" ";return g},PSEUDO:function(g,h,k,l,q){if(g[1]==="not")if((f.exec(g[3])||"").length>1||/^\w/.test(g[3]))g[3]=o(g[3],null,null,h);else{g=o.filter(g[3],h,k,true^q);k||l.push.apply(l,g);return false}else if(m.match.POS.test(g[0])||m.match.CHILD.test(g[0]))return true;return g},POS:function(g){g.unshift(true);
+return g}},filters:{enabled:function(g){return g.disabled===false&&g.type!=="hidden"},disabled:function(g){return g.disabled===true},checked:function(g){return g.checked===true},selected:function(g){return g.selected===true},parent:function(g){return!!g.firstChild},empty:function(g){return!g.firstChild},has:function(g,h,k){return!!o(k[3],g).length},header:function(g){return/h\d/i.test(g.nodeName)},text:function(g){return"text"===g.type},radio:function(g){return"radio"===g.type},checkbox:function(g){return"checkbox"===
+g.type},file:function(g){return"file"===g.type},password:function(g){return"password"===g.type},submit:function(g){return"submit"===g.type},image:function(g){return"image"===g.type},reset:function(g){return"reset"===g.type},button:function(g){return"button"===g.type||g.nodeName.toLowerCase()==="button"},input:function(g){return/input|select|textarea|button/i.test(g.nodeName)}},setFilters:{first:function(g,h){return h===0},last:function(g,h,k,l){return h===l.length-1},even:function(g,h){return h%2===
+0},odd:function(g,h){return h%2===1},lt:function(g,h,k){return h<k[3]-0},gt:function(g,h,k){return h>k[3]-0},nth:function(g,h,k){return k[3]-0===h},eq:function(g,h,k){return k[3]-0===h}},filter:{PSEUDO:function(g,h,k,l){var q=h[1],p=m.filters[q];if(p)return p(g,k,h,l);else if(q==="contains")return(g.textContent||g.innerText||a([g])||"").indexOf(h[3])>=0;else if(q==="not"){h=h[3];k=0;for(l=h.length;k<l;k++)if(h[k]===g)return false;return true}else o.error("Syntax error, unrecognized expression: "+
+q)},CHILD:function(g,h){var k=h[1],l=g;switch(k){case "only":case "first":for(;l=l.previousSibling;)if(l.nodeType===1)return false;if(k==="first")return true;l=g;case "last":for(;l=l.nextSibling;)if(l.nodeType===1)return false;return true;case "nth":k=h[2];var q=h[3];if(k===1&&q===0)return true;h=h[0];var p=g.parentNode;if(p&&(p.sizcache!==h||!g.nodeIndex)){var u=0;for(l=p.firstChild;l;l=l.nextSibling)if(l.nodeType===1)l.nodeIndex=++u;p.sizcache=h}g=g.nodeIndex-q;return k===0?g===0:g%k===0&&g/k>=
+0}},ID:function(g,h){return g.nodeType===1&&g.getAttribute("id")===h},TAG:function(g,h){return h==="*"&&g.nodeType===1||g.nodeName.toLowerCase()===h},CLASS:function(g,h){return(" "+(g.className||g.getAttribute("class"))+" ").indexOf(h)>-1},ATTR:function(g,h){var k=h[1];g=m.attrHandle[k]?m.attrHandle[k](g):g[k]!=null?g[k]:g.getAttribute(k);k=g+"";var l=h[2];h=h[4];return g==null?l==="!=":l==="="?k===h:l==="*="?k.indexOf(h)>=0:l==="~="?(" "+k+" ").indexOf(h)>=0:!h?k&&g!==false:l==="!="?k!==h:l==="^="?
+k.indexOf(h)===0:l==="$="?k.substr(k.length-h.length)===h:l==="|="?k===h||k.substr(0,h.length+1)===h+"-":false},POS:function(g,h,k,l){var q=m.setFilters[h[2]];if(q)return q(g,k,h,l)}}},s=m.match.POS;for(var x in m.match){m.match[x]=new RegExp(m.match[x].source+/(?![^\[]*\])(?![^\(]*\))/.source);m.leftMatch[x]=new RegExp(/(^(?:.|\r|\n)*?)/.source+m.match[x].source.replace(/\\(\d+)/g,function(g,h){return"\\"+(h-0+1)}))}var A=function(g,h){g=Array.prototype.slice.call(g,0);if(h){h.push.apply(h,g);return h}return g};
+try{Array.prototype.slice.call(r.documentElement.childNodes,0)}catch(B){A=function(g,h){h=h||[];if(i.call(g)==="[object Array]")Array.prototype.push.apply(h,g);else if(typeof g.length==="number")for(var k=0,l=g.length;k<l;k++)h.push(g[k]);else for(k=0;g[k];k++)h.push(g[k]);return h}}var C;if(r.documentElement.compareDocumentPosition)C=function(g,h){if(!g.compareDocumentPosition||!h.compareDocumentPosition){if(g==h)j=true;return g.compareDocumentPosition?-1:1}g=g.compareDocumentPosition(h)&4?-1:g===
+h?0:1;if(g===0)j=true;return g};else if("sourceIndex"in r.documentElement)C=function(g,h){if(!g.sourceIndex||!h.sourceIndex){if(g==h)j=true;return g.sourceIndex?-1:1}g=g.sourceIndex-h.sourceIndex;if(g===0)j=true;return g};else if(r.createRange)C=function(g,h){if(!g.ownerDocument||!h.ownerDocument){if(g==h)j=true;return g.ownerDocument?-1:1}var k=g.ownerDocument.createRange(),l=h.ownerDocument.createRange();k.setStart(g,0);k.setEnd(g,0);l.setStart(h,0);l.setEnd(h,0);g=k.compareBoundaryPoints(Range.START_TO_END,
+l);if(g===0)j=true;return g};(function(){var g=r.createElement("div"),h="script"+(new Date).getTime();g.innerHTML="<a name='"+h+"'/>";var k=r.documentElement;k.insertBefore(g,k.firstChild);if(r.getElementById(h)){m.find.ID=function(l,q,p){if(typeof q.getElementById!=="undefined"&&!p)return(q=q.getElementById(l[1]))?q.id===l[1]||typeof q.getAttributeNode!=="undefined"&&q.getAttributeNode("id").nodeValue===l[1]?[q]:v:[]};m.filter.ID=function(l,q){var p=typeof l.getAttributeNode!=="undefined"&&l.getAttributeNode("id");
+return l.nodeType===1&&p&&p.nodeValue===q}}k.removeChild(g);k=g=null})();(function(){var g=r.createElement("div");g.appendChild(r.createComment(""));if(g.getElementsByTagName("*").length>0)m.find.TAG=function(h,k){k=k.getElementsByTagName(h[1]);if(h[1]==="*"){h=[];for(var l=0;k[l];l++)k[l].nodeType===1&&h.push(k[l]);k=h}return k};g.innerHTML="<a href='#'></a>";if(g.firstChild&&typeof g.firstChild.getAttribute!=="undefined"&&g.firstChild.getAttribute("href")!=="#")m.attrHandle.href=function(h){return h.getAttribute("href",
+2)};g=null})();r.querySelectorAll&&function(){var g=o,h=r.createElement("div");h.innerHTML="<p class='TEST'></p>";if(!(h.querySelectorAll&&h.querySelectorAll(".TEST").length===0)){o=function(l,q,p,u){q=q||r;if(!u&&q.nodeType===9&&!w(q))try{return A(q.querySelectorAll(l),p)}catch(t){}return g(l,q,p,u)};for(var k in g)o[k]=g[k];h=null}}();(function(){var g=r.createElement("div");g.innerHTML="<div class='test e'></div><div class='test'></div>";if(!(!g.getElementsByClassName||g.getElementsByClassName("e").length===
+0)){g.lastChild.className="e";if(g.getElementsByClassName("e").length!==1){m.order.splice(1,0,"CLASS");m.find.CLASS=function(h,k,l){if(typeof k.getElementsByClassName!=="undefined"&&!l)return k.getElementsByClassName(h[1])};g=null}}})();var E=r.compareDocumentPosition?function(g,h){return g.compareDocumentPosition(h)&16}:function(g,h){return g!==h&&(g.contains?g.contains(h):true)},w=function(g){return(g=(g?g.ownerDocument||g:0).documentElement)?g.nodeName!=="HTML":false},fa=function(g,h){var k=[],
+l="",q;for(h=h.nodeType?[h]:h;q=m.match.PSEUDO.exec(g);){l+=q[0];g=g.replace(m.match.PSEUDO,"")}g=m.relative[g]?g+"*":g;q=0;for(var p=h.length;q<p;q++)o(g,h[q],k);return o.filter(l,k)};c.find=o;c.expr=o.selectors;c.expr[":"]=c.expr.filters;c.unique=o.uniqueSort;c.getText=a;c.isXMLDoc=w;c.contains=E})();var bb=/Until$/,cb=/^(?:parents|prevUntil|prevAll)/,db=/,/;Q=Array.prototype.slice;var Ea=function(a,b,d){if(c.isFunction(b))return c.grep(a,function(e,i){return!!b.call(e,i,e)===d});else if(b.nodeType)return c.grep(a,
+function(e){return e===b===d});else if(typeof b==="string"){var f=c.grep(a,function(e){return e.nodeType===1});if(Qa.test(b))return c.filter(b,f,!d);else b=c.filter(b,f)}return c.grep(a,function(e){return c.inArray(e,b)>=0===d})};c.fn.extend({find:function(a){for(var b=this.pushStack("","find",a),d=0,f=0,e=this.length;f<e;f++){d=b.length;c.find(a,this[f],b);if(f>0)for(var i=d;i<b.length;i++)for(var j=0;j<d;j++)if(b[j]===b[i]){b.splice(i--,1);break}}return b},has:function(a){var b=c(a);return this.filter(function(){for(var d=
+0,f=b.length;d<f;d++)if(c.contains(this,b[d]))return true})},not:function(a){return this.pushStack(Ea(this,a,false),"not",a)},filter:function(a){return this.pushStack(Ea(this,a,true),"filter",a)},is:function(a){return!!a&&c.filter(a,this).length>0},closest:function(a,b){if(c.isArray(a)){var d=[],f=this[0],e,i={},j;if(f&&a.length){e=0;for(var n=a.length;e<n;e++){j=a[e];i[j]||(i[j]=c.expr.match.POS.test(j)?c(j,b||this.context):j)}for(;f&&f.ownerDocument&&f!==b;){for(j in i){e=i[j];if(e.jquery?e.index(f)>
+-1:c(f).is(e)){d.push({selector:j,elem:f});delete i[j]}}f=f.parentNode}}return d}var o=c.expr.match.POS.test(a)?c(a,b||this.context):null;return this.map(function(m,s){for(;s&&s.ownerDocument&&s!==b;){if(o?o.index(s)>-1:c(s).is(a))return s;s=s.parentNode}return null})},index:function(a){if(!a||typeof a==="string")return c.inArray(this[0],a?c(a):this.parent().children());return c.inArray(a.jquery?a[0]:a,this)},add:function(a,b){a=typeof a==="string"?c(a,b||this.context):c.makeArray(a);b=c.merge(this.get(),
+a);return this.pushStack(pa(a[0])||pa(b[0])?b:c.unique(b))},andSelf:function(){return this.add(this.prevObject)}});c.each({parent:function(a){return(a=a.parentNode)&&a.nodeType!==11?a:null},parents:function(a){return c.dir(a,"parentNode")},parentsUntil:function(a,b,d){return c.dir(a,"parentNode",d)},next:function(a){return c.nth(a,2,"nextSibling")},prev:function(a){return c.nth(a,2,"previousSibling")},nextAll:function(a){return c.dir(a,"nextSibling")},prevAll:function(a){return c.dir(a,"previousSibling")},
+nextUntil:function(a,b,d){return c.dir(a,"nextSibling",d)},prevUntil:function(a,b,d){return c.dir(a,"previousSibling",d)},siblings:function(a){return c.sibling(a.parentNode.firstChild,a)},children:function(a){return c.sibling(a.firstChild)},contents:function(a){return c.nodeName(a,"iframe")?a.contentDocument||a.contentWindow.document:c.makeArray(a.childNodes)}},function(a,b){c.fn[a]=function(d,f){var e=c.map(this,b,d);bb.test(a)||(f=d);if(f&&typeof f==="string")e=c.filter(f,e);e=this.length>1?c.unique(e):
+e;if((this.length>1||db.test(f))&&cb.test(a))e=e.reverse();return this.pushStack(e,a,Q.call(arguments).join(","))}});c.extend({filter:function(a,b,d){if(d)a=":not("+a+")";return c.find.matches(a,b)},dir:function(a,b,d){var f=[];for(a=a[b];a&&a.nodeType!==9&&(d===v||a.nodeType!==1||!c(a).is(d));){a.nodeType===1&&f.push(a);a=a[b]}return f},nth:function(a,b,d){b=b||1;for(var f=0;a;a=a[d])if(a.nodeType===1&&++f===b)break;return a},sibling:function(a,b){for(var d=[];a;a=a.nextSibling)a.nodeType===1&&a!==
+b&&d.push(a);return d}});var Fa=/ jQuery\d+="(?:\d+|null)"/g,V=/^\s+/,Ga=/(<([\w:]+)[^>]*?)\/>/g,eb=/^(?:area|br|col|embed|hr|img|input|link|meta|param)$/i,Ha=/<([\w:]+)/,fb=/<tbody/i,gb=/<|&\w+;/,sa=/checked\s*(?:[^=]|=\s*.checked.)/i,Ia=function(a,b,d){return eb.test(d)?a:b+"></"+d+">"},F={option:[1,"<select multiple='multiple'>","</select>"],legend:[1,"<fieldset>","</fieldset>"],thead:[1,"<table>","</table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],
+col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],area:[1,"<map>","</map>"],_default:[0,"",""]};F.optgroup=F.option;F.tbody=F.tfoot=F.colgroup=F.caption=F.thead;F.th=F.td;if(!c.support.htmlSerialize)F._default=[1,"div<div>","</div>"];c.fn.extend({text:function(a){if(c.isFunction(a))return this.each(function(b){var d=c(this);d.text(a.call(this,b,d.text()))});if(typeof a!=="object"&&a!==v)return this.empty().append((this[0]&&this[0].ownerDocument||r).createTextNode(a));return c.getText(this)},
+wrapAll:function(a){if(c.isFunction(a))return this.each(function(d){c(this).wrapAll(a.call(this,d))});if(this[0]){var b=c(a,this[0].ownerDocument).eq(0).clone(true);this[0].parentNode&&b.insertBefore(this[0]);b.map(function(){for(var d=this;d.firstChild&&d.firstChild.nodeType===1;)d=d.firstChild;return d}).append(this)}return this},wrapInner:function(a){if(c.isFunction(a))return this.each(function(b){c(this).wrapInner(a.call(this,b))});return this.each(function(){var b=c(this),d=b.contents();d.length?
+d.wrapAll(a):b.append(a)})},wrap:function(a){return this.each(function(){c(this).wrapAll(a)})},unwrap:function(){return this.parent().each(function(){c.nodeName(this,"body")||c(this).replaceWith(this.childNodes)}).end()},append:function(){return this.domManip(arguments,true,function(a){this.nodeType===1&&this.appendChild(a)})},prepend:function(){return this.domManip(arguments,true,function(a){this.nodeType===1&&this.insertBefore(a,this.firstChild)})},before:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,
+false,function(b){this.parentNode.insertBefore(b,this)});else if(arguments.length){var a=c(arguments[0]);a.push.apply(a,this.toArray());return this.pushStack(a,"before",arguments)}},after:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,false,function(b){this.parentNode.insertBefore(b,this.nextSibling)});else if(arguments.length){var a=this.pushStack(this,"after",arguments);a.push.apply(a,c(arguments[0]).toArray());return a}},clone:function(a){var b=this.map(function(){if(!c.support.noCloneEvent&&
+!c.isXMLDoc(this)){var d=this.outerHTML,f=this.ownerDocument;if(!d){d=f.createElement("div");d.appendChild(this.cloneNode(true));d=d.innerHTML}return c.clean([d.replace(Fa,"").replace(V,"")],f)[0]}else return this.cloneNode(true)});if(a===true){qa(this,b);qa(this.find("*"),b.find("*"))}return b},html:function(a){if(a===v)return this[0]&&this[0].nodeType===1?this[0].innerHTML.replace(Fa,""):null;else if(typeof a==="string"&&!/<script/i.test(a)&&(c.support.leadingWhitespace||!V.test(a))&&!F[(Ha.exec(a)||
+["",""])[1].toLowerCase()]){a=a.replace(Ga,Ia);try{for(var b=0,d=this.length;b<d;b++)if(this[b].nodeType===1){c.cleanData(this[b].getElementsByTagName("*"));this[b].innerHTML=a}}catch(f){this.empty().append(a)}}else c.isFunction(a)?this.each(function(e){var i=c(this),j=i.html();i.empty().append(function(){return a.call(this,e,j)})}):this.empty().append(a);return this},replaceWith:function(a){if(this[0]&&this[0].parentNode){if(c.isFunction(a))return this.each(function(b){var d=c(this),f=d.html();d.replaceWith(a.call(this,
+b,f))});else a=c(a).detach();return this.each(function(){var b=this.nextSibling,d=this.parentNode;c(this).remove();b?c(b).before(a):c(d).append(a)})}else return this.pushStack(c(c.isFunction(a)?a():a),"replaceWith",a)},detach:function(a){return this.remove(a,true)},domManip:function(a,b,d){function f(s){return c.nodeName(s,"table")?s.getElementsByTagName("tbody")[0]||s.appendChild(s.ownerDocument.createElement("tbody")):s}var e,i,j=a[0],n=[];if(!c.support.checkClone&&arguments.length===3&&typeof j===
+"string"&&sa.test(j))return this.each(function(){c(this).domManip(a,b,d,true)});if(c.isFunction(j))return this.each(function(s){var x=c(this);a[0]=j.call(this,s,b?x.html():v);x.domManip(a,b,d)});if(this[0]){e=a[0]&&a[0].parentNode&&a[0].parentNode.nodeType===11?{fragment:a[0].parentNode}:ra(a,this,n);if(i=e.fragment.firstChild){b=b&&c.nodeName(i,"tr");for(var o=0,m=this.length;o<m;o++)d.call(b?f(this[o],i):this[o],e.cacheable||this.length>1||o>0?e.fragment.cloneNode(true):e.fragment)}n&&c.each(n,
+Ma)}return this}});c.fragments={};c.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){c.fn[a]=function(d){var f=[];d=c(d);for(var e=0,i=d.length;e<i;e++){var j=(e>0?this.clone(true):this).get();c.fn[b].apply(c(d[e]),j);f=f.concat(j)}return this.pushStack(f,a,d.selector)}});c.each({remove:function(a,b){if(!a||c.filter(a,[this]).length){if(!b&&this.nodeType===1){c.cleanData(this.getElementsByTagName("*"));c.cleanData([this])}this.parentNode&&
+this.parentNode.removeChild(this)}},empty:function(){for(this.nodeType===1&&c.cleanData(this.getElementsByTagName("*"));this.firstChild;)this.removeChild(this.firstChild)}},function(a,b){c.fn[a]=function(){return this.each(b,arguments)}});c.extend({clean:function(a,b,d,f){b=b||r;if(typeof b.createElement==="undefined")b=b.ownerDocument||b[0]&&b[0].ownerDocument||r;var e=[];c.each(a,function(i,j){if(typeof j==="number")j+="";if(j){if(typeof j==="string"&&!gb.test(j))j=b.createTextNode(j);else if(typeof j===
+"string"){j=j.replace(Ga,Ia);var n=(Ha.exec(j)||["",""])[1].toLowerCase(),o=F[n]||F._default,m=o[0];i=b.createElement("div");for(i.innerHTML=o[1]+j+o[2];m--;)i=i.lastChild;if(!c.support.tbody){m=fb.test(j);n=n==="table"&&!m?i.firstChild&&i.firstChild.childNodes:o[1]==="<table>"&&!m?i.childNodes:[];for(o=n.length-1;o>=0;--o)c.nodeName(n[o],"tbody")&&!n[o].childNodes.length&&n[o].parentNode.removeChild(n[o])}!c.support.leadingWhitespace&&V.test(j)&&i.insertBefore(b.createTextNode(V.exec(j)[0]),i.firstChild);
+j=c.makeArray(i.childNodes)}if(j.nodeType)e.push(j);else e=c.merge(e,j)}});if(d)for(a=0;e[a];a++)if(f&&c.nodeName(e[a],"script")&&(!e[a].type||e[a].type.toLowerCase()==="text/javascript"))f.push(e[a].parentNode?e[a].parentNode.removeChild(e[a]):e[a]);else{e[a].nodeType===1&&e.splice.apply(e,[a+1,0].concat(c.makeArray(e[a].getElementsByTagName("script"))));d.appendChild(e[a])}return e},cleanData:function(a){for(var b=0,d;(d=a[b])!=null;b++){c.event.remove(d);c.removeData(d)}}});var hb=/z-?index|font-?weight|opacity|zoom|line-?height/i,
+Ja=/alpha\([^)]*\)/,Ka=/opacity=([^)]*)/,ga=/float/i,ha=/-([a-z])/ig,ib=/([A-Z])/g,jb=/^-?\d+(?:px)?$/i,kb=/^-?\d/,lb={position:"absolute",visibility:"hidden",display:"block"},mb=["Left","Right"],nb=["Top","Bottom"],ob=r.defaultView&&r.defaultView.getComputedStyle,La=c.support.cssFloat?"cssFloat":"styleFloat",ia=function(a,b){return b.toUpperCase()};c.fn.css=function(a,b){return X(this,a,b,true,function(d,f,e){if(e===v)return c.curCSS(d,f);if(typeof e==="number"&&!hb.test(f))e+="px";c.style(d,f,e)})};
+c.extend({style:function(a,b,d){if(!a||a.nodeType===3||a.nodeType===8)return v;if((b==="width"||b==="height")&&parseFloat(d)<0)d=v;var f=a.style||a,e=d!==v;if(!c.support.opacity&&b==="opacity"){if(e){f.zoom=1;b=parseInt(d,10)+""==="NaN"?"":"alpha(opacity="+d*100+")";a=f.filter||c.curCSS(a,"filter")||"";f.filter=Ja.test(a)?a.replace(Ja,b):b}return f.filter&&f.filter.indexOf("opacity=")>=0?parseFloat(Ka.exec(f.filter)[1])/100+"":""}if(ga.test(b))b=La;b=b.replace(ha,ia);if(e)f[b]=d;return f[b]},css:function(a,
+b,d,f){if(b==="width"||b==="height"){var e,i=b==="width"?mb:nb;function j(){e=b==="width"?a.offsetWidth:a.offsetHeight;f!=="border"&&c.each(i,function(){f||(e-=parseFloat(c.curCSS(a,"padding"+this,true))||0);if(f==="margin")e+=parseFloat(c.curCSS(a,"margin"+this,true))||0;else e-=parseFloat(c.curCSS(a,"border"+this+"Width",true))||0})}a.offsetWidth!==0?j():c.swap(a,lb,j);return Math.max(0,Math.round(e))}return c.curCSS(a,b,d)},curCSS:function(a,b,d){var f,e=a.style;if(!c.support.opacity&&b==="opacity"&&
+a.currentStyle){f=Ka.test(a.currentStyle.filter||"")?parseFloat(RegExp.$1)/100+"":"";return f===""?"1":f}if(ga.test(b))b=La;if(!d&&e&&e[b])f=e[b];else if(ob){if(ga.test(b))b="float";b=b.replace(ib,"-$1").toLowerCase();e=a.ownerDocument.defaultView;if(!e)return null;if(a=e.getComputedStyle(a,null))f=a.getPropertyValue(b);if(b==="opacity"&&f==="")f="1"}else if(a.currentStyle){d=b.replace(ha,ia);f=a.currentStyle[b]||a.currentStyle[d];if(!jb.test(f)&&kb.test(f)){b=e.left;var i=a.runtimeStyle.left;a.runtimeStyle.left=
+a.currentStyle.left;e.left=d==="fontSize"?"1em":f||0;f=e.pixelLeft+"px";e.left=b;a.runtimeStyle.left=i}}return f},swap:function(a,b,d){var f={};for(var e in b){f[e]=a.style[e];a.style[e]=b[e]}d.call(a);for(e in b)a.style[e]=f[e]}});if(c.expr&&c.expr.filters){c.expr.filters.hidden=function(a){var b=a.offsetWidth,d=a.offsetHeight,f=a.nodeName.toLowerCase()==="tr";return b===0&&d===0&&!f?true:b>0&&d>0&&!f?false:c.curCSS(a,"display")==="none"};c.expr.filters.visible=function(a){return!c.expr.filters.hidden(a)}}var pb=
+J(),qb=/<script(.|\s)*?\/script>/gi,rb=/select|textarea/i,sb=/color|date|datetime|email|hidden|month|number|password|range|search|tel|text|time|url|week/i,N=/=\?(&|$)/,ja=/\?/,tb=/(\?|&)_=.*?(&|$)/,ub=/^(\w+:)?\/\/([^\/?#]+)/,vb=/%20/g;c.fn.extend({_load:c.fn.load,load:function(a,b,d){if(typeof a!=="string")return this._load(a);else if(!this.length)return this;var f=a.indexOf(" ");if(f>=0){var e=a.slice(f,a.length);a=a.slice(0,f)}f="GET";if(b)if(c.isFunction(b)){d=b;b=null}else if(typeof b==="object"){b=
+c.param(b,c.ajaxSettings.traditional);f="POST"}var i=this;c.ajax({url:a,type:f,dataType:"html",data:b,complete:function(j,n){if(n==="success"||n==="notmodified")i.html(e?c("<div />").append(j.responseText.replace(qb,"")).find(e):j.responseText);d&&i.each(d,[j.responseText,n,j])}});return this},serialize:function(){return c.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?c.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&
+(this.checked||rb.test(this.nodeName)||sb.test(this.type))}).map(function(a,b){a=c(this).val();return a==null?null:c.isArray(a)?c.map(a,function(d){return{name:b.name,value:d}}):{name:b.name,value:a}}).get()}});c.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(a,b){c.fn[b]=function(d){return this.bind(b,d)}});c.extend({get:function(a,b,d,f){if(c.isFunction(b)){f=f||d;d=b;b=null}return c.ajax({type:"GET",url:a,data:b,success:d,dataType:f})},getScript:function(a,
+b){return c.get(a,null,b,"script")},getJSON:function(a,b,d){return c.get(a,b,d,"json")},post:function(a,b,d,f){if(c.isFunction(b)){f=f||d;d=b;b={}}return c.ajax({type:"POST",url:a,data:b,success:d,dataType:f})},ajaxSetup:function(a){c.extend(c.ajaxSettings,a)},ajaxSettings:{url:location.href,global:true,type:"GET",contentType:"application/x-www-form-urlencoded",processData:true,async:true,xhr:z.XMLHttpRequest&&(z.location.protocol!=="file:"||!z.ActiveXObject)?function(){return new z.XMLHttpRequest}:
+function(){try{return new z.ActiveXObject("Microsoft.XMLHTTP")}catch(a){}},accepts:{xml:"application/xml, text/xml",html:"text/html",script:"text/javascript, application/javascript",json:"application/json, text/javascript",text:"text/plain",_default:"*/*"}},lastModified:{},etag:{},ajax:function(a){function b(){e.success&&e.success.call(o,n,j,w);e.global&&f("ajaxSuccess",[w,e])}function d(){e.complete&&e.complete.call(o,w,j);e.global&&f("ajaxComplete",[w,e]);e.global&&!--c.active&&c.event.trigger("ajaxStop")}
+function f(q,p){(e.context?c(e.context):c.event).trigger(q,p)}var e=c.extend(true,{},c.ajaxSettings,a),i,j,n,o=a&&a.context||e,m=e.type.toUpperCase();if(e.data&&e.processData&&typeof e.data!=="string")e.data=c.param(e.data,e.traditional);if(e.dataType==="jsonp"){if(m==="GET")N.test(e.url)||(e.url+=(ja.test(e.url)?"&":"?")+(e.jsonp||"callback")+"=?");else if(!e.data||!N.test(e.data))e.data=(e.data?e.data+"&":"")+(e.jsonp||"callback")+"=?";e.dataType="json"}if(e.dataType==="json"&&(e.data&&N.test(e.data)||
+N.test(e.url))){i=e.jsonpCallback||"jsonp"+pb++;if(e.data)e.data=(e.data+"").replace(N,"="+i+"$1");e.url=e.url.replace(N,"="+i+"$1");e.dataType="script";z[i]=z[i]||function(q){n=q;b();d();z[i]=v;try{delete z[i]}catch(p){}A&&A.removeChild(B)}}if(e.dataType==="script"&&e.cache===null)e.cache=false;if(e.cache===false&&m==="GET"){var s=J(),x=e.url.replace(tb,"$1_="+s+"$2");e.url=x+(x===e.url?(ja.test(e.url)?"&":"?")+"_="+s:"")}if(e.data&&m==="GET")e.url+=(ja.test(e.url)?"&":"?")+e.data;e.global&&!c.active++&&
+c.event.trigger("ajaxStart");s=(s=ub.exec(e.url))&&(s[1]&&s[1]!==location.protocol||s[2]!==location.host);if(e.dataType==="script"&&m==="GET"&&s){var A=r.getElementsByTagName("head")[0]||r.documentElement,B=r.createElement("script");B.src=e.url;if(e.scriptCharset)B.charset=e.scriptCharset;if(!i){var C=false;B.onload=B.onreadystatechange=function(){if(!C&&(!this.readyState||this.readyState==="loaded"||this.readyState==="complete")){C=true;b();d();B.onload=B.onreadystatechange=null;A&&B.parentNode&&
+A.removeChild(B)}}}A.insertBefore(B,A.firstChild);return v}var E=false,w=e.xhr();if(w){e.username?w.open(m,e.url,e.async,e.username,e.password):w.open(m,e.url,e.async);try{if(e.data||a&&a.contentType)w.setRequestHeader("Content-Type",e.contentType);if(e.ifModified){c.lastModified[e.url]&&w.setRequestHeader("If-Modified-Since",c.lastModified[e.url]);c.etag[e.url]&&w.setRequestHeader("If-None-Match",c.etag[e.url])}s||w.setRequestHeader("X-Requested-With","XMLHttpRequest");w.setRequestHeader("Accept",
+e.dataType&&e.accepts[e.dataType]?e.accepts[e.dataType]+", */*":e.accepts._default)}catch(fa){}if(e.beforeSend&&e.beforeSend.call(o,w,e)===false){e.global&&!--c.active&&c.event.trigger("ajaxStop");w.abort();return false}e.global&&f("ajaxSend",[w,e]);var g=w.onreadystatechange=function(q){if(!w||w.readyState===0||q==="abort"){E||d();E=true;if(w)w.onreadystatechange=c.noop}else if(!E&&w&&(w.readyState===4||q==="timeout")){E=true;w.onreadystatechange=c.noop;j=q==="timeout"?"timeout":!c.httpSuccess(w)?
+"error":e.ifModified&&c.httpNotModified(w,e.url)?"notmodified":"success";var p;if(j==="success")try{n=c.httpData(w,e.dataType,e)}catch(u){j="parsererror";p=u}if(j==="success"||j==="notmodified")i||b();else c.handleError(e,w,j,p);d();q==="timeout"&&w.abort();if(e.async)w=null}};try{var h=w.abort;w.abort=function(){w&&h.call(w);g("abort")}}catch(k){}e.async&&e.timeout>0&&setTimeout(function(){w&&!E&&g("timeout")},e.timeout);try{w.send(m==="POST"||m==="PUT"||m==="DELETE"?e.data:null)}catch(l){c.handleError(e,
+w,null,l);d()}e.async||g();return w}},handleError:function(a,b,d,f){if(a.error)a.error.call(a.context||a,b,d,f);if(a.global)(a.context?c(a.context):c.event).trigger("ajaxError",[b,a,f])},active:0,httpSuccess:function(a){try{return!a.status&&location.protocol==="file:"||a.status>=200&&a.status<300||a.status===304||a.status===1223||a.status===0}catch(b){}return false},httpNotModified:function(a,b){var d=a.getResponseHeader("Last-Modified"),f=a.getResponseHeader("Etag");if(d)c.lastModified[b]=d;if(f)c.etag[b]=
+f;return a.status===304||a.status===0},httpData:function(a,b,d){var f=a.getResponseHeader("content-type")||"",e=b==="xml"||!b&&f.indexOf("xml")>=0;a=e?a.responseXML:a.responseText;e&&a.documentElement.nodeName==="parsererror"&&c.error("parsererror");if(d&&d.dataFilter)a=d.dataFilter(a,b);if(typeof a==="string")if(b==="json"||!b&&f.indexOf("json")>=0)a=c.parseJSON(a);else if(b==="script"||!b&&f.indexOf("javascript")>=0)c.globalEval(a);return a},param:function(a,b){function d(j,n){if(c.isArray(n))c.each(n,
+function(o,m){b?f(j,m):d(j+"["+(typeof m==="object"||c.isArray(m)?o:"")+"]",m)});else!b&&n!=null&&typeof n==="object"?c.each(n,function(o,m){d(j+"["+o+"]",m)}):f(j,n)}function f(j,n){n=c.isFunction(n)?n():n;e[e.length]=encodeURIComponent(j)+"="+encodeURIComponent(n)}var e=[];if(b===v)b=c.ajaxSettings.traditional;if(c.isArray(a)||a.jquery)c.each(a,function(){f(this.name,this.value)});else for(var i in a)d(i,a[i]);return e.join("&").replace(vb,"+")}});var ka={},wb=/toggle|show|hide/,xb=/^([+-]=)?([\d+-.]+)(.*)$/,
+W,ta=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]];c.fn.extend({show:function(a,b){if(a||a===0)return this.animate(K("show",3),a,b);else{a=0;for(b=this.length;a<b;a++){var d=c.data(this[a],"olddisplay");this[a].style.display=d||"";if(c.css(this[a],"display")==="none"){d=this[a].nodeName;var f;if(ka[d])f=ka[d];else{var e=c("<"+d+" />").appendTo("body");f=e.css("display");if(f==="none")f="block";e.remove();
+ka[d]=f}c.data(this[a],"olddisplay",f)}}a=0;for(b=this.length;a<b;a++)this[a].style.display=c.data(this[a],"olddisplay")||"";return this}},hide:function(a,b){if(a||a===0)return this.animate(K("hide",3),a,b);else{a=0;for(b=this.length;a<b;a++){var d=c.data(this[a],"olddisplay");!d&&d!=="none"&&c.data(this[a],"olddisplay",c.css(this[a],"display"))}a=0;for(b=this.length;a<b;a++)this[a].style.display="none";return this}},_toggle:c.fn.toggle,toggle:function(a,b){var d=typeof a==="boolean";if(c.isFunction(a)&&
+c.isFunction(b))this._toggle.apply(this,arguments);else a==null||d?this.each(function(){var f=d?a:c(this).is(":hidden");c(this)[f?"show":"hide"]()}):this.animate(K("toggle",3),a,b);return this},fadeTo:function(a,b,d){return this.filter(":hidden").css("opacity",0).show().end().animate({opacity:b},a,d)},animate:function(a,b,d,f){var e=c.speed(b,d,f);if(c.isEmptyObject(a))return this.each(e.complete);return this[e.queue===false?"each":"queue"](function(){var i=c.extend({},e),j,n=this.nodeType===1&&c(this).is(":hidden"),
+o=this;for(j in a){var m=j.replace(ha,ia);if(j!==m){a[m]=a[j];delete a[j];j=m}if(a[j]==="hide"&&n||a[j]==="show"&&!n)return i.complete.call(this);if((j==="height"||j==="width")&&this.style){i.display=c.css(this,"display");i.overflow=this.style.overflow}if(c.isArray(a[j])){(i.specialEasing=i.specialEasing||{})[j]=a[j][1];a[j]=a[j][0]}}if(i.overflow!=null)this.style.overflow="hidden";i.curAnim=c.extend({},a);c.each(a,function(s,x){var A=new c.fx(o,i,s);if(wb.test(x))A[x==="toggle"?n?"show":"hide":x](a);
+else{var B=xb.exec(x),C=A.cur(true)||0;if(B){x=parseFloat(B[2]);var E=B[3]||"px";if(E!=="px"){o.style[s]=(x||1)+E;C=(x||1)/A.cur(true)*C;o.style[s]=C+E}if(B[1])x=(B[1]==="-="?-1:1)*x+C;A.custom(C,x,E)}else A.custom(C,x,"")}});return true})},stop:function(a,b){var d=c.timers;a&&this.queue([]);this.each(function(){for(var f=d.length-1;f>=0;f--)if(d[f].elem===this){b&&d[f](true);d.splice(f,1)}});b||this.dequeue();return this}});c.each({slideDown:K("show",1),slideUp:K("hide",1),slideToggle:K("toggle",
+1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"}},function(a,b){c.fn[a]=function(d,f){return this.animate(b,d,f)}});c.extend({speed:function(a,b,d){var f=a&&typeof a==="object"?a:{complete:d||!d&&b||c.isFunction(a)&&a,duration:a,easing:d&&b||b&&!c.isFunction(b)&&b};f.duration=c.fx.off?0:typeof f.duration==="number"?f.duration:c.fx.speeds[f.duration]||c.fx.speeds._default;f.old=f.complete;f.complete=function(){f.queue!==false&&c(this).dequeue();c.isFunction(f.old)&&f.old.call(this)};return f},easing:{linear:function(a,
+b,d,f){return d+f*a},swing:function(a,b,d,f){return(-Math.cos(a*Math.PI)/2+0.5)*f+d}},timers:[],fx:function(a,b,d){this.options=b;this.elem=a;this.prop=d;if(!b.orig)b.orig={}}});c.fx.prototype={update:function(){this.options.step&&this.options.step.call(this.elem,this.now,this);(c.fx.step[this.prop]||c.fx.step._default)(this);if((this.prop==="height"||this.prop==="width")&&this.elem.style)this.elem.style.display="block"},cur:function(a){if(this.elem[this.prop]!=null&&(!this.elem.style||this.elem.style[this.prop]==
+null))return this.elem[this.prop];return(a=parseFloat(c.css(this.elem,this.prop,a)))&&a>-10000?a:parseFloat(c.curCSS(this.elem,this.prop))||0},custom:function(a,b,d){function f(i){return e.step(i)}this.startTime=J();this.start=a;this.end=b;this.unit=d||this.unit||"px";this.now=this.start;this.pos=this.state=0;var e=this;f.elem=this.elem;if(f()&&c.timers.push(f)&&!W)W=setInterval(c.fx.tick,13)},show:function(){this.options.orig[this.prop]=c.style(this.elem,this.prop);this.options.show=true;this.custom(this.prop===
+"width"||this.prop==="height"?1:0,this.cur());c(this.elem).show()},hide:function(){this.options.orig[this.prop]=c.style(this.elem,this.prop);this.options.hide=true;this.custom(this.cur(),0)},step:function(a){var b=J(),d=true;if(a||b>=this.options.duration+this.startTime){this.now=this.end;this.pos=this.state=1;this.update();this.options.curAnim[this.prop]=true;for(var f in this.options.curAnim)if(this.options.curAnim[f]!==true)d=false;if(d){if(this.options.display!=null){this.elem.style.overflow=
+this.options.overflow;a=c.data(this.elem,"olddisplay");this.elem.style.display=a?a:this.options.display;if(c.css(this.elem,"display")==="none")this.elem.style.display="block"}this.options.hide&&c(this.elem).hide();if(this.options.hide||this.options.show)for(var e in this.options.curAnim)c.style(this.elem,e,this.options.orig[e]);this.options.complete.call(this.elem)}return false}else{e=b-this.startTime;this.state=e/this.options.duration;a=this.options.easing||(c.easing.swing?"swing":"linear");this.pos=
+c.easing[this.options.specialEasing&&this.options.specialEasing[this.prop]||a](this.state,e,0,1,this.options.duration);this.now=this.start+(this.end-this.start)*this.pos;this.update()}return true}};c.extend(c.fx,{tick:function(){for(var a=c.timers,b=0;b<a.length;b++)a[b]()||a.splice(b--,1);a.length||c.fx.stop()},stop:function(){clearInterval(W);W=null},speeds:{slow:600,fast:200,_default:400},step:{opacity:function(a){c.style(a.elem,"opacity",a.now)},_default:function(a){if(a.elem.style&&a.elem.style[a.prop]!=
+null)a.elem.style[a.prop]=(a.prop==="width"||a.prop==="height"?Math.max(0,a.now):a.now)+a.unit;else a.elem[a.prop]=a.now}}});if(c.expr&&c.expr.filters)c.expr.filters.animated=function(a){return c.grep(c.timers,function(b){return a===b.elem}).length};c.fn.offset="getBoundingClientRect"in r.documentElement?function(a){var b=this[0];if(a)return this.each(function(e){c.offset.setOffset(this,a,e)});if(!b||!b.ownerDocument)return null;if(b===b.ownerDocument.body)return c.offset.bodyOffset(b);var d=b.getBoundingClientRect(),
+f=b.ownerDocument;b=f.body;f=f.documentElement;return{top:d.top+(self.pageYOffset||c.support.boxModel&&f.scrollTop||b.scrollTop)-(f.clientTop||b.clientTop||0),left:d.left+(self.pageXOffset||c.support.boxModel&&f.scrollLeft||b.scrollLeft)-(f.clientLeft||b.clientLeft||0)}}:function(a){var b=this[0];if(a)return this.each(function(s){c.offset.setOffset(this,a,s)});if(!b||!b.ownerDocument)return null;if(b===b.ownerDocument.body)return c.offset.bodyOffset(b);c.offset.initialize();var d=b.offsetParent,f=
+b,e=b.ownerDocument,i,j=e.documentElement,n=e.body;f=(e=e.defaultView)?e.getComputedStyle(b,null):b.currentStyle;for(var o=b.offsetTop,m=b.offsetLeft;(b=b.parentNode)&&b!==n&&b!==j;){if(c.offset.supportsFixedPosition&&f.position==="fixed")break;i=e?e.getComputedStyle(b,null):b.currentStyle;o-=b.scrollTop;m-=b.scrollLeft;if(b===d){o+=b.offsetTop;m+=b.offsetLeft;if(c.offset.doesNotAddBorder&&!(c.offset.doesAddBorderForTableAndCells&&/^t(able|d|h)$/i.test(b.nodeName))){o+=parseFloat(i.borderTopWidth)||
+0;m+=parseFloat(i.borderLeftWidth)||0}f=d;d=b.offsetParent}if(c.offset.subtractsBorderForOverflowNotVisible&&i.overflow!=="visible"){o+=parseFloat(i.borderTopWidth)||0;m+=parseFloat(i.borderLeftWidth)||0}f=i}if(f.position==="relative"||f.position==="static"){o+=n.offsetTop;m+=n.offsetLeft}if(c.offset.supportsFixedPosition&&f.position==="fixed"){o+=Math.max(j.scrollTop,n.scrollTop);m+=Math.max(j.scrollLeft,n.scrollLeft)}return{top:o,left:m}};c.offset={initialize:function(){var a=r.body,b=r.createElement("div"),
+d,f,e,i=parseFloat(c.curCSS(a,"marginTop",true))||0;c.extend(b.style,{position:"absolute",top:0,left:0,margin:0,border:0,width:"1px",height:"1px",visibility:"hidden"});b.innerHTML="<div style='position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;'><div></div></div><table style='position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;' cellpadding='0' cellspacing='0'><tr><td></td></tr></table>";a.insertBefore(b,a.firstChild);
+d=b.firstChild;f=d.firstChild;e=d.nextSibling.firstChild.firstChild;this.doesNotAddBorder=f.offsetTop!==5;this.doesAddBorderForTableAndCells=e.offsetTop===5;f.style.position="fixed";f.style.top="20px";this.supportsFixedPosition=f.offsetTop===20||f.offsetTop===15;f.style.position=f.style.top="";d.style.overflow="hidden";d.style.position="relative";this.subtractsBorderForOverflowNotVisible=f.offsetTop===-5;this.doesNotIncludeMarginInBodyOffset=a.offsetTop!==i;a.removeChild(b);c.offset.initialize=c.noop},
+bodyOffset:function(a){var b=a.offsetTop,d=a.offsetLeft;c.offset.initialize();if(c.offset.doesNotIncludeMarginInBodyOffset){b+=parseFloat(c.curCSS(a,"marginTop",true))||0;d+=parseFloat(c.curCSS(a,"marginLeft",true))||0}return{top:b,left:d}},setOffset:function(a,b,d){if(/static/.test(c.curCSS(a,"position")))a.style.position="relative";var f=c(a),e=f.offset(),i=parseInt(c.curCSS(a,"top",true),10)||0,j=parseInt(c.curCSS(a,"left",true),10)||0;if(c.isFunction(b))b=b.call(a,d,e);d={top:b.top-e.top+i,left:b.left-
+e.left+j};"using"in b?b.using.call(a,d):f.css(d)}};c.fn.extend({position:function(){if(!this[0])return null;var a=this[0],b=this.offsetParent(),d=this.offset(),f=/^body|html$/i.test(b[0].nodeName)?{top:0,left:0}:b.offset();d.top-=parseFloat(c.curCSS(a,"marginTop",true))||0;d.left-=parseFloat(c.curCSS(a,"marginLeft",true))||0;f.top+=parseFloat(c.curCSS(b[0],"borderTopWidth",true))||0;f.left+=parseFloat(c.curCSS(b[0],"borderLeftWidth",true))||0;return{top:d.top-f.top,left:d.left-f.left}},offsetParent:function(){return this.map(function(){for(var a=
+this.offsetParent||r.body;a&&!/^body|html$/i.test(a.nodeName)&&c.css(a,"position")==="static";)a=a.offsetParent;return a})}});c.each(["Left","Top"],function(a,b){var d="scroll"+b;c.fn[d]=function(f){var e=this[0],i;if(!e)return null;if(f!==v)return this.each(function(){if(i=ua(this))i.scrollTo(!a?f:c(i).scrollLeft(),a?f:c(i).scrollTop());else this[d]=f});else return(i=ua(e))?"pageXOffset"in i?i[a?"pageYOffset":"pageXOffset"]:c.support.boxModel&&i.document.documentElement[d]||i.document.body[d]:e[d]}});
+c.each(["Height","Width"],function(a,b){var d=b.toLowerCase();c.fn["inner"+b]=function(){return this[0]?c.css(this[0],d,false,"padding"):null};c.fn["outer"+b]=function(f){return this[0]?c.css(this[0],d,false,f?"margin":"border"):null};c.fn[d]=function(f){var e=this[0];if(!e)return f==null?null:this;if(c.isFunction(f))return this.each(function(i){var j=c(this);j[d](f.call(this,i,j[d]()))});return"scrollTo"in e&&e.document?e.document.compatMode==="CSS1Compat"&&e.document.documentElement["client"+b]||
+e.document.body["client"+b]:e.nodeType===9?Math.max(e.documentElement["client"+b],e.body["scroll"+b],e.documentElement["scroll"+b],e.body["offset"+b],e.documentElement["offset"+b]):f===v?c.css(e,d):this.css(d,typeof f==="string"?f:f+"px")}});z.jQuery=z.$=c})(window);
diff --git a/railties/lib/generators/rails/app/templates/public/javascripts/jquery.rails.js b/railties/lib/generators/rails/app/templates/public/javascripts/jquery.rails.js
new file mode 100644
index 0000000000..887da514e2
--- /dev/null
+++ b/railties/lib/generators/rails/app/templates/public/javascripts/jquery.rails.js
@@ -0,0 +1,239 @@
+jQuery(function ($) {
+ var rails = {
+ update: function (selector, content, position) {
+ var element = $('#' + selector);
+ if (position) {
+ switch (position) {
+ case "before":
+ element.before(content);
+ break;
+ case "after":
+ element.after(content);
+ break;
+ case "top":
+ element.prepend(content);
+ break;
+ case "bottom":
+ element.append(content);
+ break;
+ default:
+ element.append(content);
+ break;
+ }
+ } else {
+ element.html(content);
+ }
+ },
+ remote: function (e) {
+ var el = $(this),
+ data = [],
+ condition = el.attr('data-condition') ? eval(el.attr('data-condition')) : true,
+ method = el.attr('method') || el.attr('data-method') || 'GET',
+ url = el.attr('action') || el.attr('data-url') || '#',
+ async = el.attr('data-remote-type') === 'synchronous' ? false : true;
+
+ if (el.attr('data-submit')) {
+ data = $('#' + el.attr('data-submit')).serializeArray();
+ } else if (el.attr('data-with')) {
+
+ if (e && e.target.tagName.toUpperCase() == 'SCRIPT' && el.attr('data-observed') !== null) {
+ var observed = $('#' + el.attr('data-observed'));
+ if(observed[0].tagName.toUpperCase() === 'FORM'){
+ data = el.attr('data-with') + '=' + observed.serialize();
+ } else if(observed[0].tagName.toUpperCase() === 'INPUT' && observed.attr('type').toUpperCase() !== "BUTTON" && observed.attr('type').toUpperCase() !== "SUBMIT") {
+ data = el.attr('data-with') + '=' + observed.val();
+ }
+ } else {
+ // TODO: remove eval when deprecated
+ data = eval(el.attr('data-with'));
+ }
+ } else if (e && e.target.tagName.toUpperCase() == 'FORM') {
+ data = el.serializeArray();
+ } else if (e && e.target.tagName.toUpperCase() == 'INPUT') {
+ data = el.closest('form').serializeArray();
+ }
+
+ if (condition) {
+ el.trigger('rails:before');
+
+ $.ajax({
+ async: async,
+ url: url,
+ data: data,
+ type: method.toUpperCase(),
+ beforeSend: function (xhr) {
+ xhr.setRequestHeader("Accept", "text/javascript")
+ el.trigger('rails:after', xhr);
+ el.trigger('rails:loading', xhr);
+ },
+ success: function (data, status, xhr) {
+ el.trigger('rails:success', [data, status, xhr]);
+ if (el.attr('data-update-success')) {
+ rails.update(el.attr('data-update-success'), data, el.attr('data-update-position'));
+ }
+ },
+ complete: function (xhr) {
+ // enable disabled_with buttons
+ if (el[0].tagName.toUpperCase() == 'FORM') {
+ el.children('input[type="button"][data-enable-with],input[type="submit"][data-enable-with]').each(function(i, button){
+ button = $(button);
+ button.attr('value', button.attr('data-enable-with'));
+ button.removeAttr('data-enable-with');
+ button.removeAttr('disabled');
+
+ });
+ } else {
+ el.attr('value', el.attr('data-enable-with'));
+ el.removeAttr('data-enable-with');
+ el.removeAttr('disabled');
+ }
+
+ el.trigger('rails:complete', xhr);
+ el.trigger('rails:loaded', xhr);
+ },
+ error: function (xhr, status, error) {
+ el.trigger('rails:failure', [xhr, status, error]);
+ if (el.attr('data-update-failure')) {
+ rails.update(el.attr('data-update-failure'), xhr.responseText, el.attr('data-update-position'));
+ }
+ }
+ });
+ }
+ e.preventDefault();
+ }
+ }
+
+ /**
+ * observe_form, and observe_field
+ */
+ $('script[data-observe="true"]').each(function (index, e) {
+ var el = $(e),
+ observed = $('#' + $(e).attr('data-observed'));
+ frequency = el.attr('data-frequency') ? el.attr('data-frequency') : 10,
+ value = observed[0].tagName.toUpperCase() === 'FORM' ? observed.serialize() : observed.val();
+
+ var observe = function (observed, frequency, value, e) {
+ return function () {
+ var event = new jQuery.Event('periodical'),
+ newValue = observed[0].tagName.toUpperCase() === 'FORM' ? observed.serialize() : observed.val();
+ event.target = e;
+
+ if(value !== newValue) {
+ value = newValue;
+ $(e).trigger('rails:observe');
+ rails.remote.call(el, event);
+ }
+ }
+ }(observed, frequency, value, e);
+
+ setInterval(observe, frequency * 1000);
+ });
+
+ /**
+ * confirm
+ * make sure this event is first!
+ */
+ $('a[data-confirm],input[type="submit"][data-confirm],input[type="button"][data-confirm]').live('click', function(e){
+ var el = $(this);
+
+ if(!confirm(el.attr('data-confirm'))){
+ return false;
+ }
+ });
+
+ /**
+ * periodically_call_remote
+ */
+ $('script[data-periodical="true"]').each(function (index, e) {
+ var el = $(e),
+ frequency = el.attr('data-frequency') ? el.attr('data-frequency') : 10;
+
+ setInterval(function () {
+ return function () {
+ var event = new jQuery.Event('periodical');
+ event.target = e;
+
+ rails.remote.call(el, event);
+ }
+ }(e, el), frequency * 1000);
+ });
+
+ /**
+ * disable_with
+ */
+ $('input[type="button"][data-disable-with],input[type="submit"][data-disable-with]').live('click', function(e){
+ var el = $(this);
+
+ el.attr('data-enable-with', el.attr('value'));
+ el.attr('disabled', 'disabled');
+ el.attr('value', el.attr('data-disable-with'));
+ });
+
+ /**
+ * remote_form_tag, and remote_form_for
+ */
+ $('form[data-remote="true"]').live('submit', rails.remote);
+
+ /**
+ * link_to_remote, button_to_remote, and submit_to_remote
+ */
+ $('a[data-remote="true"],input[data-remote="true"],input[data-remote-submit="true"]').live('click', rails.remote);
+
+ /*
+ * popup
+ */
+ $('a[data-popup],input[type="button"][data-popup]').live('click', function(e){
+ var el = $(this),
+ url = el.attr('data-url') || el.attr('href');
+
+ e.preventDefault();
+
+ if(el.attr('data-popup') === "true"){
+ window.open(url);
+ } else {
+ window.open(url, el.attr('data-popup'));
+ }
+ });
+
+ /**
+ *
+ * Rails 2.x Helper / Event Handlers
+ * By default we listen to all callbacks, and status code callbacks and
+ * check the element for data-<callback> attribute and eval it.
+ *
+ */
+ rails.compat = {
+ evalAttribute: function (element, attribute) {
+ var el = $(element),
+ attr = el.attr('data-' + attribute);
+ return (attr) ? eval(attr) : true;
+ }
+ };
+
+ $('form[data-remote="true"],a[data-remote="true"],input[data-remote="true"],script[data-observe="true"]')
+ .live('rails:before', function (e) {
+ rails.compat.evalAttribute(this, 'onbefore');
+ })
+ .live('rails:after', function (e, xhr) {
+ rails.compat.evalAttribute(this, 'onafter');
+ })
+ .live('rails:loading', function (e, xhr) {
+ rails.compat.evalAttribute(this, 'onloading');
+ })
+ .live('rails:loaded', function (e, xhr) {
+ rails.compat.evalAttribute(this, 'onloaded');
+ })
+ .live('rails:complete', function (e, xhr) {
+ rails.compat.evalAttribute(this, 'oncomplete');
+ rails.compat.evalAttribute(this, 'on' + xhr.status);
+ })
+ .live('rails:success', function (e, data, status, xhr) {
+ rails.compat.evalAttribute(this, 'onsuccess');
+ })
+ .live('rails:failure', function (e, xhr, status, error) {
+ rails.compat.evalAttribute(this, 'onfailure');
+ })
+ .live('rails:observe', function (e) {
+ rails.compat.evalAttribute(this, 'onobserve');
+ });
+});
diff --git a/railties/lib/generators/rails/app/templates/public/javascripts/prototype.rails.js b/railties/lib/generators/rails/app/templates/public/javascripts/prototype.rails.js
new file mode 100644
index 0000000000..aaed677fda
--- /dev/null
+++ b/railties/lib/generators/rails/app/templates/public/javascripts/prototype.rails.js
@@ -0,0 +1,324 @@
+Event.observe(document, 'dom:loaded', function() {
+ function handle_remote(el, e){
+ var data = null,
+ method = el.readAttribute('method') || el.readAttribute('data-method') || 'GET',
+ url = el.readAttribute('action') || el.readAttribute('data-url') || '#',
+ async = el.readAttribute('data-remote-type') === 'synchronous' ? false : true,
+ update = el.readAttribute('data-update-success'),
+ position = el.readAttribute('data-update-position');
+
+ if (el.readAttribute('data-submit')) {
+ var submit_el = $(el.readAttribute('data-submit'));
+ if(submit_el !== undefined && submit_el.tagName.toUpperCase() == 'FORM'){
+ data = submit_el.serialize();
+ }
+ } else if (el.readAttribute('data-with')) {
+ // It seems there is a big inconsistency between what :with means depending on the element type
+ // so this is going to look a bit crazy
+ if(el.tagName.toUpperCase() === 'SCRIPT' && el.readAttribute('data-observed') !== null){
+ // Handle observe_field and observe_form
+ var observed_element = $(el.readAttribute('data-observed'));
+
+ if(observed_element.tagName.toUpperCase() === 'FORM'){
+ data = el.readAttribute('data-with') + '=' + observed_element.serialize();
+ } else if(observed_element.tagName.toUpperCase() === 'INPUT' && observed_element.readAttribute('type').toUpperCase() !== "BUTTON" && observed_element.readAttribute('type').toUpperCase() !== "SUBMIT") {
+ data = el.readAttribute('data-with') + '=' + observed_element.getValue();
+ }
+ } else {
+ // Handle link_to and button_to
+ data = evalAttribute(el, 'data-with');
+ }
+ } else if(el.tagName.toUpperCase() === 'FORM') {
+ data = el.serialize();
+ }
+
+ document.fire('rails:before');
+
+ var request = new Ajax.Request(url, {
+ method: method,
+ asynchronous: async,
+ parameters: data,
+ evalJS: true,
+ evalJSON: true,
+ onComplete: function(xhr){
+ document.fire('rails:complete', {xhr: xhr, element: el, submitted_button: getEventProperty(e, 'submitted_button')});
+ },
+ onLoading: function(xhr){
+ document.fire('rails:after', {xhr: xhr, element: el});
+ document.fire('rails:loading', {xhr: xhr, element: el});
+ },
+ onLoaded: function(xhr){
+ document.fire('rails:loaded', {xhr: xhr, element: el});
+ },
+ onSuccess: function(xhr){
+ document.fire('rails:success', {xhr: xhr, element: el});
+ },
+ onFailure: function(xhr){
+ document.fire('rails:failure', {xhr: xhr, element: el});
+ }
+ });
+
+ }
+
+ function setEventProperty(e, property, value){
+ if(e.memo === undefined){
+ e.memo = {};
+ }
+
+ e.memo[property] = value;
+ }
+
+ function getEventProperty(e, property){
+ if(e !== null && e.memo !== undefined && e.memo[property] !== undefined){
+ return e.memo[property];
+ }
+ }
+
+ function confirmed(e, el){
+ if(getEventProperty(e,'confirm_checked') !== true){
+ setEventProperty(e, 'confirm_checked', true);
+
+ el = Event.findElement(e, 'form') || el;
+ var confirm_msg = el.readAttribute('data-confirm');
+
+ if(confirm_msg !== null){
+ var result = el.fire('rails:confirm', {confirm_msg: confirm_msg});
+ if(result.memo.stop_event === true){
+ Event.stop(e);
+ return false;
+ }
+ }
+ }
+ return true;
+ }
+
+ function disable_button(el){
+ var disable_with = el.readAttribute('data-disable-with');
+ if(disable_with !== null){
+ el.writeAttribute('data-enable-with', el.readAttribute('value'));
+ el.writeAttribute('value', disable_with);
+ el.writeAttribute('disabled', true);
+ }
+ }
+
+ function enable_button(el){
+ var enable_with = el.readAttribute('data-enable-with');
+ if(enable_with !== null){
+ el.writeAttribute('value', enable_with);
+ }
+ el.writeAttribute('disabled', false);
+ }
+
+ function updateHTML(el, content, result){
+ var element_id = null;
+
+ if(result === 'success'){
+ element_id = el.readAttribute('data-update-success');
+ } else if(result === 'failure'){
+ element_id = el.readAttribute('data-update-failure');
+ }
+
+ var element_to_update = $(element_id);
+ if(element_to_update !== null){
+ var position = el.readAttribute('data-update-position');
+ if(position !== null){
+ var options = {};
+ options[position] = content;
+ element_to_update.insert(options);
+ } else {
+ element_to_update.update(content);
+ }
+ }
+ }
+
+ $$("script[data-periodical=true]").each(function(el){
+ var executor = new PeriodicalExecuter(function() { handle_remote(el);}, el.readAttribute('data-frequency'));
+ });
+
+ $$("script[data-observe=true]").each(function(el){
+ var observed_element = $(el.readAttribute('data-observed'));
+ var original_value = observed_element.tagName.toUpperCase() === 'FORM' ? observed_element.serialize() : observed_element.getValue();
+ var callback = el.readAttribute('data-onobserve');
+ var executor = new PeriodicalExecuter(function() {
+ var value = observed_element.tagName.toUpperCase() === 'FORM' ? observed_element.serialize() : observed_element.getValue();
+
+ if(original_value !== value){
+ original_value = value;
+
+ if(callback !== null){
+ evalAttribute(el, 'onobserve');
+ } else if(el.readAttribute('data-url') !== null){
+ handle_remote(el);
+ }
+ }
+ }, el.readAttribute('data-frequency'));
+
+ });
+
+ /**
+ *
+ * Event Listeners
+ *
+ * the original element is contained inside the event,
+ * for some reason prototype wont let me listen for custom events on document
+ * if the event wasn't fired on document
+ *
+ */
+
+ Event.observe(document, 'submit', function (e) {
+ var form = Event.findElement(e, 'form');
+ // Make sure conditions and confirm have not already run
+ if(form !== undefined && conditions_met(e, form) && confirmed(e, form)){
+
+ var button = form.down('input[data-submitted=true]');
+ button.writeAttribute('data-submitted', null);
+ setEventProperty(e, 'submitted_button', button);
+ disable_button(button);
+
+ if(form.readAttribute('data-remote') === 'true'){
+ Event.stop(e);
+ handle_remote(form, e);
+ }
+ }
+ });
+
+ Event.observe(document, 'click', function (e) {
+ var el = Event.findElement(e, 'a') || Event.findElement(e, 'input');
+
+ if(el !== undefined && el.tagName.toUpperCase() === 'INPUT' && el.readAttribute('type').toUpperCase() === 'SUBMIT'){
+ el.writeAttribute('data-submitted', 'true');
+
+ // Submit is handled by submit event, don't continue on this path
+ el = undefined;
+ } else if(el !== undefined && el.tagName.toUpperCase() === 'INPUT' && el.readAttribute('type').toUpperCase() !== 'BUTTON'){
+ // Make sure other inputs do not send this event
+ el = undefined;
+ }
+
+ if(el !== undefined && conditions_met(e, el) && confirmed(e, el)){
+ if(el.tagName.toUpperCase() === 'INPUT' && el.readAttribute('type').toUpperCase() === 'BUTTON'){
+ disable_button(el);
+ }
+
+ if(el.readAttribute('data-remote') === 'true'){
+ Event.stop(e);
+ handle_remote(el, e);
+ } else if(el.readAttribute('data-popup') !== null){
+ Event.stop(e);
+ document.fire('rails:popup', {element: el});
+ }
+ }
+ });
+
+ /**
+ *
+ * Default Event Handlers
+ *
+ */
+ Event.observe(document, 'rails:confirm', function(e){
+ setEventProperty(e, 'stop_event', !confirm(getEventProperty(e,'confirm_msg')));
+ });
+
+ Event.observe(document, 'rails:popup', function(e){
+ var el = getEventProperty(e, 'element');
+ var url = el.readAttribute('href') || el.readAttribute('data-url');
+
+ if(el.readAttribute('data-popup') === true){
+ window.open(url);
+ } else {
+ window.open(url, el.readAttribute('data-popup'));
+ }
+ });
+
+ Event.observe(document, 'rails:complete', function(e){
+ var el = getEventProperty(e, 'element');
+
+ if(el.tagName.toUpperCase() === 'FORM'){
+ var button = getEventProperty(e, 'submitted_button') ;
+ enable_button(button);
+ }
+ });
+
+ Event.observe(document, 'rails:success', function(e){
+ var el = getEventProperty(e, 'element'),
+ xhr = getEventProperty(e, 'xhr');
+
+ if(xhr.responseText !== null){
+ updateHTML(el, xhr.responseText, 'success');
+ }
+ });
+
+ Event.observe(document, 'rails:failure', function(e){
+ var el = getEventProperty(e, 'element'),
+ xhr = getEventProperty(e, 'xhr');
+
+ if(xhr.responseText !== null){
+ updateHTML(el, xhr.responseText, 'failure');
+ }
+ });
+
+ /**
+ *
+ * Rails 2.x Helpers / Event Handlers
+ *
+ */
+ function evalAttribute(el, attribute){
+ var js = el.readAttribute('data-' + attribute);
+
+ if(js){
+ eval(js);
+ }
+ }
+
+ function conditions_met(e, el){
+ if(getEventProperty(e,'condition_checked') !== true){
+ setEventProperty(e, 'condition_checked', true);
+
+ el = Event.findElement(e, 'form') || el;
+ var conditions = el.readAttribute('data-condition');
+
+ if(conditions !== null){
+ if(eval(conditions) === false){
+ Event.stop(e);
+ return false;
+ }
+ }
+ }
+ return true;
+ }
+
+ Event.observe(document, 'rails:success', function(e){
+ evalAttribute(el, 'onsuccess');
+ });
+
+ Event.observe(document, 'rails:failure', function(e){
+ evalAttribute(el, 'onfailure');
+ });
+
+ Event.observe(document, 'rails:complete', function(e){
+ var el = getEventProperty(e, 'element');
+
+ evalAttribute(el, 'oncomplete');
+ evalAttribute(el, 'on' + getEventProperty('xhr', xhr.status));
+
+ if(el.readAttribute('data-periodical') === 'true'){
+ evalAttribute(el, 'onobserve');
+ }
+ });
+
+ Event.observe(document, 'rails:loading', function(e){
+ evalAttribute(el, 'onloading');
+ });
+
+ Event.observe(document, 'rails:loaded', function(e){
+ evalAttribute(el, 'onloaded');
+ });
+
+ Event.observe(document, 'rails:before', function(e){
+ evalAttribute(el, 'onbefore');
+ });
+
+ Event.observe(document, 'rails:after', function(e){
+ evalAttribute(el, 'onafter');
+ });
+});
diff --git a/railties/lib/generators/rails/app/templates/script/console.tt b/railties/lib/generators/rails/app/templates/script/console.tt
index 915c5b8294..47aa254f9f 100755
--- a/railties/lib/generators/rails/app/templates/script/console.tt
+++ b/railties/lib/generators/rails/app/templates/script/console.tt
@@ -2,4 +2,4 @@ require File.expand_path('../../config/boot', __FILE__)
require 'rails/commands/console'
require File.expand_path('../../config/application', __FILE__)
-Rails::Console.start(<%= app_const %>)
+Rails::Console.start(Rails::Application)
diff --git a/railties/lib/generators/rails/app/templates/script/dbconsole.tt b/railties/lib/generators/rails/app/templates/script/dbconsole.tt
index a92f6f2844..1e53c1d761 100755
--- a/railties/lib/generators/rails/app/templates/script/dbconsole.tt
+++ b/railties/lib/generators/rails/app/templates/script/dbconsole.tt
@@ -2,4 +2,4 @@ require File.expand_path('../../config/boot', __FILE__)
require 'rails/commands/dbconsole'
require File.expand_path('../../config/application', __FILE__)
-Rails::DBConsole.start(<%= app_const %>)
+Rails::DBConsole.start(Rails::Application)
diff --git a/railties/lib/generators/rails/mailer/templates/mailer.rb b/railties/lib/generators/rails/mailer/templates/mailer.rb
index 90e0b712d6..7343eb28b3 100644
--- a/railties/lib/generators/rails/mailer/templates/mailer.rb
+++ b/railties/lib/generators/rails/mailer/templates/mailer.rb
@@ -1,14 +1,16 @@
class <%= class_name %> < ActionMailer::Base
+ default :from => "from@example.com"
<% for action in actions -%>
- def <%= action %>(sent_at = Time.now)
- subject '<%= class_name %>#<%= action %>'
- recipients ''
- from ''
- sent_on sent_at
-
- body :greeting => 'Hi,'
- end
+ # Subject can be set in your I18n file at config/locales/en.yml
+ # with the following lookup:
+ #
+ # en.actionmailer.<%= file_name %>.<%= action %>.subject
+ #
+ def <%= action %>
+ @greeting = "Hi"
+ mail :to => "to@example.org"
+ end
<% end -%>
end
diff --git a/railties/lib/generators/rails/metal/templates/metal.rb b/railties/lib/generators/rails/metal/templates/metal.rb
index 2f5d4e7593..8cc3f1f258 100644
--- a/railties/lib/generators/rails/metal/templates/metal.rb
+++ b/railties/lib/generators/rails/metal/templates/metal.rb
@@ -1,5 +1,5 @@
# Allow the metal piece to run in isolation
-require File.expand_path('../../../config/environment', __FILE__)
+require File.expand_path('../../../config/environment', __FILE__) unless defined?(Rails)
class <%= class_name %>
def self.call(env)
diff --git a/railties/lib/generators/rails/plugin/plugin_generator.rb b/railties/lib/generators/rails/plugin/plugin_generator.rb
index b68b8691db..8f01dcd589 100644
--- a/railties/lib/generators/rails/plugin/plugin_generator.rb
+++ b/railties/lib/generators/rails/plugin/plugin_generator.rb
@@ -17,7 +17,7 @@ module Rails
def create_tasks_files
return unless options[:tasks]
- directory 'tasks', plugin_dir('tasks')
+ directory 'lib/tasks', plugin_dir('lib/tasks')
end
hook_for :generator do |generator|
diff --git a/railties/lib/generators/rails/plugin/templates/tasks/%file_name%_tasks.rake.tt b/railties/lib/generators/rails/plugin/templates/lib/tasks/%file_name%_tasks.rake.tt
index 72920a9d3a..72920a9d3a 100644
--- a/railties/lib/generators/rails/plugin/templates/tasks/%file_name%_tasks.rake.tt
+++ b/railties/lib/generators/rails/plugin/templates/lib/tasks/%file_name%_tasks.rake.tt
diff --git a/railties/lib/generators/rails/resource/resource_generator.rb b/railties/lib/generators/rails/resource/resource_generator.rb
index 43c7cc85f4..5acb839f39 100644
--- a/railties/lib/generators/rails/resource/resource_generator.rb
+++ b/railties/lib/generators/rails/resource/resource_generator.rb
@@ -6,8 +6,8 @@ module Rails
class ResourceGenerator < ModelGenerator #metagenerator
include ResourceHelpers
- hook_for :resource_controller, :required => true do |base, controller|
- base.invoke controller, [ base.controller_name, base.options[:actions] ]
+ hook_for :resource_controller, :required => true do |controller|
+ invoke controller, [ controller_name, options[:actions] ]
end
class_option :actions, :type => :array, :banner => "ACTION ACTION", :default => [],
diff --git a/railties/lib/generators/rails/scaffold_controller/scaffold_controller_generator.rb b/railties/lib/generators/rails/scaffold_controller/scaffold_controller_generator.rb
index e544e29892..49af2974cd 100644
--- a/railties/lib/generators/rails/scaffold_controller/scaffold_controller_generator.rb
+++ b/railties/lib/generators/rails/scaffold_controller/scaffold_controller_generator.rb
@@ -18,9 +18,9 @@ module Rails
hook_for :template_engine, :test_framework, :as => :scaffold
- # Invoke the helper using the controller (pluralized) name.
- hook_for :helper, :as => :scaffold do |base, invoked|
- base.invoke invoked, [ base.controller_name ]
+ # Invoke the helper using the controller name (pluralized)
+ hook_for :helper, :as => :scaffold do |invoked|
+ invoke invoked, [ controller_name ]
end
end
end
diff --git a/railties/lib/generators/test_unit/mailer/templates/fixture b/railties/lib/generators/test_unit/mailer/templates/fixture
index fcce7bd805..171648d6fd 100644
--- a/railties/lib/generators/test_unit/mailer/templates/fixture
+++ b/railties/lib/generators/test_unit/mailer/templates/fixture
@@ -1,3 +1,3 @@
<%= class_name %>#<%= @action %>
-Find me in app/views/<%= @path %>
+Hi, find me in app/views/<%= @path %>
diff --git a/railties/lib/generators/test_unit/mailer/templates/functional_test.rb b/railties/lib/generators/test_unit/mailer/templates/functional_test.rb
index 4de94076e9..e1aeb2db90 100644
--- a/railties/lib/generators/test_unit/mailer/templates/functional_test.rb
+++ b/railties/lib/generators/test_unit/mailer/templates/functional_test.rb
@@ -3,11 +3,13 @@ require 'test_helper'
class <%= class_name %>Test < ActionMailer::TestCase
<% for action in actions -%>
test "<%= action %>" do
- @expected.subject = '<%= class_name %>#<%= action %>'
- @expected.body = read_fixture('<%= action %>')
+ @expected.subject = <%= action.to_s.humanize.inspect %>
+ @expected.to = "to@example.org"
+ @expected.from = "from@example.com"
+ @expected.body = read_fixture("<%= action %>")
@expected.date = Time.now
- assert_equal @expected.encoded, <%= class_name %>.create_<%= action %>(@expected.date).encoded
+ assert_equal @expected, <%= class_name %>.<%= action %>
end
<% end -%>
diff --git a/railties/lib/rails.rb b/railties/lib/rails.rb
index 0bc7160815..b7a39fd5a7 100644
--- a/railties/lib/rails.rb
+++ b/railties/lib/rails.rb
@@ -4,19 +4,13 @@ require 'active_support'
require 'active_support/core_ext/kernel/reporting'
require 'active_support/core_ext/logger'
-require 'rails/initializable'
require 'rails/application'
-require 'rails/railtie'
-require 'rails/plugin'
-require 'rails/railties_path'
require 'rails/version'
-require 'rails/rack'
-require 'rails/paths'
-require 'rails/configuration'
require 'rails/deprecation'
require 'rails/subscriber'
require 'rails/ruby_version_check'
+require 'active_support/railtie'
require 'action_dispatch/railtie'
# For Ruby 1.8, this initialization sets $KCODE to 'u' to enable the
@@ -32,8 +26,6 @@ else
end
module Rails
- autoload :Bootstrap, 'rails/bootstrap'
-
class << self
def application
@@application ||= nil
diff --git a/railties/lib/rails/all.rb b/railties/lib/rails/all.rb
index 7dfe2b8b63..1a0b4a8d73 100644
--- a/railties/lib/rails/all.rb
+++ b/railties/lib/rails/all.rb
@@ -1,12 +1,14 @@
require "rails"
%w(
+ active_support
active_model
active_record
action_controller
action_view
action_mailer
active_resource
+ rails/test_unit
).each do |framework|
begin
require "#{framework}/railtie"
diff --git a/railties/lib/rails/application.rb b/railties/lib/rails/application.rb
index 8366127476..9384492486 100644
--- a/railties/lib/rails/application.rb
+++ b/railties/lib/rails/application.rb
@@ -1,118 +1,93 @@
-require "fileutils"
-require 'active_support/core_ext/module/delegation'
+require 'fileutils'
+require 'rails/railties_path'
+require 'rails/plugin'
+require 'rails/engine'
module Rails
- class Application
- include Initializable
+ class Application < Engine
+ autoload :Bootstrap, 'rails/application/bootstrap'
+ autoload :Configurable, 'rails/application/configurable'
+ autoload :Configuration, 'rails/application/configuration'
+ autoload :Finisher, 'rails/application/finisher'
+ autoload :MetalLoader, 'rails/application/metal_loader'
+ autoload :Railties, 'rails/application/railties'
+ autoload :RoutesReloader, 'rails/application/routes_reloader'
class << self
- attr_writer :config
- alias configure class_eval
- delegate :call,
- :initialize!,
- :load_generators,
- :load_tasks,
- :middleware,
- :root,
- :to => :instance
-
private :new
+ alias :configure :class_eval
+
def instance
- @instance ||= new
+ if self == Rails::Application
+ Rails.application
+ else
+ @@instance ||= new
+ end
end
- def config
- @config ||= Configuration.new(Plugin::Configuration.default)
+ def inherited(base)
+ raise "You cannot have more than one Rails::Application" if Rails.application
+ super
+ Rails.application = base.instance
end
- def routes
- ActionController::Routing::Routes
+ def respond_to?(*args)
+ super || instance.respond_to?(*args)
end
- end
- delegate :config, :routes, :to => :'self.class'
- delegate :root, :middleware, :to => :config
- attr_reader :route_configuration_files
+ protected
- def initialize
- require_environment
- Rails.application ||= self
- @route_configuration_files = []
+ def method_missing(*args, &block)
+ instance.send(*args, &block)
+ end
end
- def initialize!
- run_initializers(self)
- self
+ def require_environment!
+ environment = config.paths.config.environment.to_a.first
+ require environment if environment
end
- def require_environment
- require config.environment_path
- rescue LoadError
+ def routes
+ ::ActionController::Routing::Routes
end
- def routes_changed_at
- routes_changed_at = nil
-
- route_configuration_files.each do |config|
- config_changed_at = File.stat(config).mtime
+ def railties
+ @railties ||= Railties.new(config)
+ end
- if routes_changed_at.nil? || config_changed_at > routes_changed_at
- routes_changed_at = config_changed_at
- end
- end
+ def metal_loader
+ @metal_laoder ||= MetalLoader.new
+ end
- routes_changed_at
+ def routes_reloader
+ @routes_reloader ||= RoutesReloader.new
end
def reload_routes!
- routes.disable_clear_and_finalize = true
-
- routes.clear!
- route_configuration_files.each { |config| load(config) }
- routes.finalize!
+ routes_reloader.reload!
+ end
- nil
- ensure
- routes.disable_clear_and_finalize = false
+ def initialize!
+ run_initializers(self)
+ self
end
def load_tasks
- require "rails/tasks"
- plugins.each { |p| p.load_tasks }
- # Load all application tasks
- # TODO: extract out the path to the rake tasks
- Dir["#{root}/lib/tasks/**/*.rake"].sort.each { |ext| load ext }
- task :environment do
- $rails_rake_task = true
- initialize!
- end
+ initialize_tasks
+ super
+ railties.all { |r| r.load_tasks }
+ self
end
def load_generators
- plugins.each { |p| p.load_generators }
- end
-
- def initializers
- initializers = Bootstrap.new(self).initializers
- plugins.each { |p| initializers += p.initializers }
- initializers += super
- initializers
- end
-
- # TODO: Fix this method. It loads all railties independent if :all is given
- # or not, otherwise frameworks are never loaded.
- def plugins
- @plugins ||= begin
- plugin_names = (config.plugins || [:all]).map { |p| p.to_sym }
- Railtie.plugins.map(&:new) + Plugin.all(plugin_names, config.paths.vendor.plugins)
- end
+ initialize_generators
+ super
+ railties.all { |r| r.load_generators }
+ self
end
def app
- @app ||= begin
- reload_routes!
- middleware.build(routes)
- end
+ @app ||= middleware.build(routes)
end
def call(env)
@@ -120,42 +95,31 @@ module Rails
app.call(env)
end
- initializer :load_application_initializers do
- Dir["#{root}/config/initializers/**/*.rb"].sort.each do |initializer|
- load(initializer)
- end
+ def initializers
+ initializers = Bootstrap.initializers_for(self)
+ railties.all { |r| initializers += r.initializers }
+ initializers += super
+ initializers += Finisher.initializers_for(self)
+ initializers
end
- initializer :build_middleware_stack do
- app
- end
+ protected
- # Fires the user-supplied after_initialize block (Configuration#after_initialize)
- initializer :after_initialize do
- config.after_initialize_blocks.each do |block|
- block.call
+ def initialize_tasks
+ require "rails/tasks"
+ task :environment do
+ $rails_rake_task = true
+ initialize!
end
end
- # Eager load application classes
- initializer :load_application_classes do
- next if $rails_rake_task
-
- if config.cache_classes
- config.eager_load_paths.each do |load_path|
- matcher = /\A#{Regexp.escape(load_path)}(.*)\.rb\Z/
- Dir.glob("#{load_path}/**/*.rb").sort.each do |file|
- require_dependency file.sub(matcher, '\1')
- end
- end
- end
+ def initialize_generators
+ require "rails/generators"
end
- # Disable dependency loading during request cycle
- initializer :disable_dependency_loading do
- if config.cache_classes && !config.dependency_loading
- ActiveSupport::Dependencies.unhook!
- end
+ # Application is always reloadable when config.cache_classes is false.
+ def reloadable?(app)
+ true
end
end
end
diff --git a/railties/lib/rails/application/bootstrap.rb b/railties/lib/rails/application/bootstrap.rb
new file mode 100644
index 0000000000..b20e53f2de
--- /dev/null
+++ b/railties/lib/rails/application/bootstrap.rb
@@ -0,0 +1,85 @@
+module Rails
+ class Application
+ module Bootstrap
+ include Initializable
+
+ initializer :load_environment_config do
+ require_environment!
+ end
+
+ initializer :load_all_active_support do
+ require "active_support/all" unless config.active_support.bare
+ end
+
+ # Preload all frameworks specified by the Configuration#frameworks.
+ # Used by Passenger to ensure everything's loaded before forking and
+ # to avoid autoload race conditions in JRuby.
+ initializer :preload_frameworks do
+ require 'active_support/dependencies'
+ ActiveSupport::Autoload.eager_autoload! if config.preload_frameworks
+ end
+
+ # Initialize the logger early in the stack in case we need to log some deprecation.
+ initializer :initialize_logger do
+ Rails.logger ||= config.logger || begin
+ path = config.paths.log.to_a.first
+ logger = ActiveSupport::BufferedLogger.new(path)
+ logger.level = ActiveSupport::BufferedLogger.const_get(config.log_level.to_s.upcase)
+ logger.auto_flushing = false if Rails.env.production?
+ logger
+ rescue StandardError => e
+ logger = ActiveSupport::BufferedLogger.new(STDERR)
+ logger.level = ActiveSupport::BufferedLogger::WARN
+ logger.warn(
+ "Rails Error: Unable to access log file. Please ensure that #{path} exists and is chmod 0666. " +
+ "The log level has been raised to WARN and the output directed to STDERR until the problem is fixed."
+ )
+ logger
+ end
+ end
+
+ # Initialize cache early in the stack so railties can make use of it.
+ initializer :initialize_cache do
+ unless defined?(RAILS_CACHE)
+ silence_warnings { Object.const_set "RAILS_CACHE", ActiveSupport::Cache.lookup_store(config.cache_store) }
+
+ if RAILS_CACHE.respond_to?(:middleware)
+ config.middleware.insert_after(:"Rack::Lock", RAILS_CACHE.middleware)
+ end
+ end
+ end
+
+ # Initialize rails subscriber on top of notifications.
+ initializer :initialize_subscriber do
+ require 'active_support/notifications'
+
+ if config.colorize_logging == false
+ Rails::Subscriber.colorize_logging = false
+ config.generators.colorize_logging = false
+ end
+
+ ActiveSupport::Notifications.subscribe do |*args|
+ Rails::Subscriber.dispatch(args)
+ end
+ end
+
+ initializer :set_clear_dependencies_hook do
+ unless config.cache_classes
+ ActionDispatch::Callbacks.after do
+ ActiveSupport::Dependencies.clear
+ end
+ end
+ end
+
+ # Sets the dependency loading mechanism.
+ # TODO: Remove files from the $" and always use require.
+ initializer :initialize_dependency_mechanism do
+ ActiveSupport::Dependencies.mechanism = config.cache_classes ? :require : :load
+ end
+
+ initializer :bootstrap_load_path do
+ # This is just an initializer used as hook so all load paths are loaded together
+ end
+ end
+ end
+end \ No newline at end of file
diff --git a/railties/lib/rails/application/configurable.rb b/railties/lib/rails/application/configurable.rb
new file mode 100644
index 0000000000..f598e33965
--- /dev/null
+++ b/railties/lib/rails/application/configurable.rb
@@ -0,0 +1,19 @@
+module Rails
+ class Application
+ module Configurable
+ def self.included(base)
+ base.extend ClassMethods
+ end
+
+ module ClassMethods
+ def inherited(base)
+ raise "You cannot inherit from a Rails::Application child"
+ end
+ end
+
+ def config
+ @config ||= Application::Configuration.new(self.class.find_root_with_flag("config.ru", Dir.pwd))
+ end
+ end
+ end
+end \ No newline at end of file
diff --git a/railties/lib/rails/application/configuration.rb b/railties/lib/rails/application/configuration.rb
new file mode 100644
index 0000000000..31787b5cc9
--- /dev/null
+++ b/railties/lib/rails/application/configuration.rb
@@ -0,0 +1,84 @@
+require 'rails/engine/configuration'
+
+module Rails
+ class Application
+ class Configuration < ::Rails::Engine::Configuration
+ include ::Rails::Configuration::Deprecated
+
+ attr_accessor :cache_classes, :cache_store, :colorize_logging,
+ :consider_all_requests_local, :dependency_loading,
+ :filter_parameters, :log_level, :logger, :metals,
+ :plugins, :preload_frameworks, :reload_engines, :reload_plugins,
+ :serve_static_assets, :time_zone, :whiny_nils
+
+ def initialize(*)
+ super
+ @colorize_logging = true
+ @filter_parameters = []
+ @dependency_loading = true
+ @serve_static_assets = true
+ @time_zone = "UTC"
+ end
+
+ def paths
+ @paths ||= begin
+ paths = super
+ paths.app.controllers << builtin_controller if builtin_controller
+ paths.config.database "config/database.yml"
+ paths.config.environment "config/environments", :glob => "#{Rails.env}.rb"
+ paths.log "log/#{Rails.env}.log"
+ paths.tmp "tmp"
+ paths.tmp.cache "tmp/cache"
+ paths.vendor "vendor", :load_path => true
+ paths.vendor.plugins "vendor/plugins"
+
+ if File.exists?("#{root}/test/mocks/#{Rails.env}")
+ ActiveSupport::Deprecation.warn "\"RAILS_ROOT/test/mocks/#{Rails.env}\" won't be added " <<
+ "automatically to load paths anymore in future releases"
+ paths.mocks_path "test/mocks", :load_path => true, :glob => Rails.env
+ end
+
+ paths
+ end
+ end
+
+ # Enable threaded mode. Allows concurrent requests to controller actions and
+ # multiple database connections. Also disables automatic dependency loading
+ # after boot, and disables reloading code on every request, as these are
+ # fundamentally incompatible with thread safety.
+ def threadsafe!
+ self.preload_frameworks = true
+ self.cache_classes = true
+ self.dependency_loading = false
+ self.action_controller.allow_concurrency = true if respond_to?(:action_controller)
+ self
+ end
+
+ # Loads and returns the contents of the #database_configuration_file. The
+ # contents of the file are processed via ERB before being sent through
+ # YAML::load.
+ def database_configuration
+ require 'erb'
+ YAML::load(ERB.new(IO.read(paths.config.database.to_a.first)).result)
+ end
+
+ def cache_store
+ @cache_store ||= begin
+ if File.exist?("#{root}/tmp/cache/")
+ [ :file_store, "#{root}/tmp/cache/" ]
+ else
+ :memory_store
+ end
+ end
+ end
+
+ def builtin_controller
+ File.join(RAILTIES_PATH, "builtin", "rails_info") if Rails.env.development?
+ end
+
+ def log_level
+ @log_level ||= Rails.env.production? ? :info : :debug
+ end
+ end
+ end
+end \ No newline at end of file
diff --git a/railties/lib/rails/application/finisher.rb b/railties/lib/rails/application/finisher.rb
new file mode 100644
index 0000000000..b722679ec2
--- /dev/null
+++ b/railties/lib/rails/application/finisher.rb
@@ -0,0 +1,49 @@
+module Rails
+ class Application
+ module Finisher
+ include Initializable
+
+ initializer :ensure_load_once_paths_as_subset do
+ extra = ActiveSupport::Dependencies.load_once_paths -
+ ActiveSupport::Dependencies.load_paths
+
+ unless extra.empty?
+ abort <<-end_error
+ load_once_paths must be a subset of the load_paths.
+ Extra items in load_once_paths: #{extra * ','}
+ end_error
+ end
+ end
+
+ initializer :add_to_prepare_blocks do
+ config.to_prepare_blocks.each do |block|
+ ActionDispatch::Callbacks.to_prepare(&block)
+ end
+ end
+
+ initializer :add_builtin_route do |app|
+ if Rails.env.development?
+ app.routes_reloader.paths << File.join(RAILTIES_PATH, 'builtin', 'routes.rb')
+ end
+ end
+
+ initializer :build_middleware_stack do
+ app
+ end
+
+ # Fires the user-supplied after_initialize block (config.after_initialize)
+ initializer :after_initialize do
+ config.after_initialize_blocks.each do |block|
+ block.call(self)
+ end
+ end
+
+ # Disable dependency loading during request cycle
+ initializer :disable_dependency_loading do
+ if config.cache_classes && !config.dependency_loading
+ ActiveSupport::Dependencies.unhook!
+ end
+ end
+ end
+ end
+end \ No newline at end of file
diff --git a/railties/lib/rails/application/metal_loader.rb b/railties/lib/rails/application/metal_loader.rb
new file mode 100644
index 0000000000..c0f2e4f948
--- /dev/null
+++ b/railties/lib/rails/application/metal_loader.rb
@@ -0,0 +1,50 @@
+require 'action_dispatch'
+
+module Rails
+ class Application
+ class MetalLoader
+ attr_reader :paths, :metals
+
+ def initialize
+ @paths, @metals = [], []
+ end
+
+ def build_middleware(list=nil)
+ load_metals!(list)
+ self
+ end
+
+ def new(app)
+ ActionDispatch::Cascade.new(@metals, app)
+ end
+
+ def name
+ ActionDispatch::Cascade.name
+ end
+ alias :to_s :name
+
+ protected
+
+ def load_metals!(list)
+ metals = []
+ list = Array(list || :all).map(&:to_sym)
+
+ paths.each do |path|
+ matcher = /\A#{Regexp.escape(path)}\/(.*)\.rb\Z/
+ Dir.glob("#{path}/**/*.rb").sort.each do |metal_path|
+ metal = metal_path.sub(matcher, '\1').to_sym
+ next unless list.include?(metal) || list.include?(:all)
+ require_dependency metal
+ metals << metal
+ end
+ end
+
+ metals = metals.sort_by do |m|
+ [list.index(m) || list.index(:all), m.to_s]
+ end
+
+ @metals = metals.map { |m| m.to_s.camelize.constantize }
+ end
+ end
+ end
+end
diff --git a/railties/lib/rails/application/railties.rb b/railties/lib/rails/application/railties.rb
new file mode 100644
index 0000000000..b3e6693f89
--- /dev/null
+++ b/railties/lib/rails/application/railties.rb
@@ -0,0 +1,31 @@
+module Rails
+ class Application
+ class Railties
+ # TODO Write tests for this behavior extracted from Application
+ def initialize(config)
+ @config = config
+ end
+
+ def all(&block)
+ @all ||= railties + engines + plugins
+ @all.each(&block) if block
+ @all
+ end
+
+ def railties
+ @railties ||= ::Rails::Railtie.subclasses.map(&:new)
+ end
+
+ def engines
+ @engines ||= ::Rails::Engine.subclasses.map(&:new)
+ end
+
+ def plugins
+ @plugins ||= begin
+ plugin_names = (@config.plugins || [:all]).map { |p| p.to_sym }
+ Plugin.all(plugin_names, @config.paths.vendor.plugins)
+ end
+ end
+ end
+ end
+end \ No newline at end of file
diff --git a/railties/lib/rails/application/routes_reloader.rb b/railties/lib/rails/application/routes_reloader.rb
new file mode 100644
index 0000000000..fde6211c5d
--- /dev/null
+++ b/railties/lib/rails/application/routes_reloader.rb
@@ -0,0 +1,46 @@
+module Rails
+ class Application
+ class RoutesReloader
+ attr_reader :paths
+
+ def initialize
+ @paths, @last_change_at = [], nil
+ end
+
+ def changed_at
+ routes_changed_at = nil
+
+ paths.each do |path|
+ config_changed_at = File.stat(path).mtime
+
+ if routes_changed_at.nil? || config_changed_at > routes_changed_at
+ routes_changed_at = config_changed_at
+ end
+ end
+
+ routes_changed_at
+ end
+
+ def reload!
+ routes = Rails::Application.routes
+ routes.disable_clear_and_finalize = true
+
+ routes.clear!
+ paths.each { |path| load(path) }
+ routes.finalize!
+
+ nil
+ ensure
+ routes.disable_clear_and_finalize = false
+ end
+
+ def reload_if_changed
+ current_change_at = changed_at
+ if @last_change_at != current_change_at
+ @last_change_at = current_change_at
+ reload!
+ end
+ end
+ end
+ end
+end \ No newline at end of file
diff --git a/railties/lib/rails/bootstrap.rb b/railties/lib/rails/bootstrap.rb
deleted file mode 100644
index 5db663f9ef..0000000000
--- a/railties/lib/rails/bootstrap.rb
+++ /dev/null
@@ -1,161 +0,0 @@
-module Rails
- class Bootstrap #< Railtie
- include Initializable
-
- def initialize(application)
- @application = application
- end
-
- delegate :config, :root, :to => :'@application'
-
- initializer :load_all_active_support do
- require "active_support/all" unless config.active_support.bare
- end
-
- # Set the <tt>$LOAD_PATH</tt> based on the value of
- # Configuration#load_paths. Duplicates are removed.
- initializer :set_load_path do
- config.paths.add_to_load_path
- $LOAD_PATH.uniq!
- end
-
- # Set the paths from which Rails will automatically load source files, and
- # the load_once paths.
- initializer :set_autoload_paths do
- require 'active_support/dependencies'
- ActiveSupport::Dependencies.load_paths = expand_load_path(config.load_paths)
- ActiveSupport::Dependencies.load_once_paths = expand_load_path(config.load_once_paths)
-
- extra = ActiveSupport::Dependencies.load_once_paths - ActiveSupport::Dependencies.load_paths
- unless extra.empty?
- abort <<-end_error
- load_once_paths must be a subset of the load_paths.
- Extra items in load_once_paths: #{extra * ','}
- end_error
- end
-
- # Freeze the arrays so future modifications will fail rather than do nothing mysteriously
- config.load_once_paths.freeze
- end
-
- # Create tmp directories
- initializer :ensure_tmp_directories_exist do
- %w(cache pids sessions sockets).each do |dir_to_make|
- FileUtils.mkdir_p(File.join(root, 'tmp', dir_to_make))
- end
- end
-
- # Preload all frameworks specified by the Configuration#frameworks.
- # Used by Passenger to ensure everything's loaded before forking and
- # to avoid autoload race conditions in JRuby.
- initializer :preload_frameworks do
- ActiveSupport::Autoload.eager_autoload! if config.preload_frameworks
- end
-
- initializer :initialize_cache do
- unless defined?(RAILS_CACHE)
- silence_warnings { Object.const_set "RAILS_CACHE", ActiveSupport::Cache.lookup_store(config.cache_store) }
-
- if RAILS_CACHE.respond_to?(:middleware)
- # Insert middleware to setup and teardown local cache for each request
- config.middleware.insert_after(:"Rack::Lock", RAILS_CACHE.middleware)
- end
- end
- end
-
- initializer :initialize_logger do
- Rails.logger ||= config.logger || begin
- logger = ActiveSupport::BufferedLogger.new(config.log_path)
- logger.level = ActiveSupport::BufferedLogger.const_get(config.log_level.to_s.upcase)
- logger.auto_flushing = false if Rails.env.production?
- logger
- rescue StandardError => e
- logger = ActiveSupport::BufferedLogger.new(STDERR)
- logger.level = ActiveSupport::BufferedLogger::WARN
- logger.warn(
- "Rails Error: Unable to access log file. Please ensure that #{config.log_path} exists and is chmod 0666. " +
- "The log level has been raised to WARN and the output directed to STDERR until the problem is fixed."
- )
- logger
- end
- end
-
- # Sets the logger for dependencies and cache store.
- initializer :initialize_framework_logging do
- ActiveSupport::Dependencies.logger ||= Rails.logger
- Rails.cache.logger ||= Rails.logger
- end
-
- # Sets the dependency loading mechanism based on the value of
- # Configuration#cache_classes.
- initializer :initialize_dependency_mechanism do
- # TODO: Remove files from the $" and always use require
- ActiveSupport::Dependencies.mechanism = config.cache_classes ? :require : :load
- end
-
- # Loads support for "whiny nil" (noisy warnings when methods are invoked
- # on +nil+ values) if Configuration#whiny_nils is true.
- initializer :initialize_whiny_nils do
- require 'active_support/whiny_nil' if config.whiny_nils
- end
-
- # Sets the default value for Time.zone
- # If assigned value cannot be matched to a TimeZone, an exception will be raised.
- initializer :initialize_time_zone do
- require 'active_support/core_ext/time/zones'
- zone_default = Time.__send__(:get_zone, config.time_zone)
-
- unless zone_default
- raise \
- 'Value assigned to config.time_zone not recognized.' +
- 'Run "rake -D time" for a list of tasks for finding appropriate time zone names.'
- end
-
- Time.zone_default = zone_default
- end
-
- # Set the i18n configuration from config.i18n but special-case for the load_path which should be
- # appended to what's already set instead of overwritten.
- initializer :initialize_i18n do
- require 'active_support/i18n'
-
- config.i18n.each do |setting, value|
- if setting == :load_path
- I18n.load_path += value
- else
- I18n.send("#{setting}=", value)
- end
- end
-
- ActionDispatch::Callbacks.to_prepare do
- I18n.reload!
- end
- end
-
- initializer :set_clear_dependencies_hook do
- unless config.cache_classes
- ActionDispatch::Callbacks.after do
- ActiveSupport::Dependencies.clear
- end
- end
- end
-
- initializer :initialize_notifications do
- require 'active_support/notifications'
-
- if config.colorize_logging == false
- Rails::Subscriber.colorize_logging = false
- config.generators.colorize_logging = false
- end
-
- ActiveSupport::Notifications.subscribe do |*args|
- Rails::Subscriber.dispatch(args)
- end
- end
-
- private
- def expand_load_path(load_paths)
- load_paths.map { |path| Dir.glob(path.to_s) }.flatten.uniq
- end
- end
-end
diff --git a/railties/lib/rails/commands/console.rb b/railties/lib/rails/commands/console.rb
index 27ac7fd20a..a984eff6e2 100644
--- a/railties/lib/rails/commands/console.rb
+++ b/railties/lib/rails/commands/console.rb
@@ -1,6 +1,6 @@
require 'optparse'
require 'irb'
-require "irb/completion"
+require 'irb/completion'
module Rails
class Console
@@ -24,9 +24,9 @@ module Rails
end
@app.initialize!
- require "rails/console_app"
- require "rails/console_sandbox" if options[:sandbox]
- require "rails/console_with_helpers"
+ require "rails/console/app"
+ require "rails/console/sandbox" if options[:sandbox]
+ require "rails/console/helpers"
if options[:debugger]
begin
diff --git a/railties/lib/rails/configuration.rb b/railties/lib/rails/configuration.rb
index 7f1783a6b9..a95075562f 100644
--- a/railties/lib/rails/configuration.rb
+++ b/railties/lib/rails/configuration.rb
@@ -1,294 +1,90 @@
require 'active_support/ordered_options'
+require 'rails/paths'
+require 'rails/rack'
module Rails
- # Temporarily separate the plugin configuration class from the main
- # configuration class while this bit is being cleaned up.
- class Railtie::Configuration
- def self.default
- @default ||= new
- end
-
- def self.default_middleware_stack
- ActionDispatch::MiddlewareStack.new.tap do |middleware|
- middleware.use('::ActionDispatch::Static', lambda { Rails.public_path }, :if => lambda { Rails.application.config.serve_static_assets })
- middleware.use('::Rack::Lock', :if => lambda { !ActionController::Base.allow_concurrency })
- middleware.use('::Rack::Runtime')
- middleware.use('::Rails::Rack::Logger')
- middleware.use('::ActionDispatch::ShowExceptions', lambda { ActionController::Base.consider_all_requests_local })
- middleware.use('::ActionDispatch::Callbacks', lambda { !Rails.application.config.cache_classes })
- middleware.use('::ActionDispatch::Cookies')
- middleware.use(lambda { ActionController::Base.session_store }, lambda { ActionController::Base.session_options })
- middleware.use('::ActionDispatch::Flash', :if => lambda { ActionController::Base.session_store })
- middleware.use(lambda { Rails::Rack::Metal.new(Rails.application.config.paths.app.metals.to_a, Rails.application.config.metals) })
- middleware.use('ActionDispatch::ParamsParser')
- middleware.use('::Rack::MethodOverride')
- middleware.use('::ActionDispatch::Head')
- end
- end
-
- attr_reader :middleware
-
- def initialize(base = nil)
- if base
- @options = base.options.dup
- @middleware = base.middleware.dup
- else
- @options = Hash.new { |h,k| h[k] = ActiveSupport::OrderedOptions.new }
- @middleware = self.class.default_middleware_stack
- end
- end
-
- def respond_to?(name)
- super || name.to_s =~ config_key_regexp
- end
-
- protected
-
- attr_reader :options
-
- private
-
- def method_missing(name, *args, &blk)
- if name.to_s =~ config_key_regexp
- return $2 == '=' ? @options[$1] = args.first : @options[$1]
+ module Configuration
+ module Shared
+ def middleware
+ @@default_middleware_stack ||= ActionDispatch::MiddlewareStack.new.tap do |middleware|
+ middleware.use('::ActionDispatch::Static', lambda { Rails.public_path }, :if => lambda { Rails.application.config.serve_static_assets })
+ middleware.use('::Rack::Lock', :if => lambda { !ActionController::Base.allow_concurrency })
+ middleware.use('::Rack::Runtime')
+ middleware.use('::Rails::Rack::Logger')
+ middleware.use('::ActionDispatch::ShowExceptions', lambda { ActionController::Base.consider_all_requests_local })
+ middleware.use('::ActionDispatch::Callbacks', lambda { !Rails.application.config.cache_classes })
+ middleware.use('::ActionDispatch::Cookies')
+ middleware.use(lambda { ActionController::Base.session_store }, lambda { ActionController::Base.session_options })
+ middleware.use('::ActionDispatch::Flash', :if => lambda { ActionController::Base.session_store })
+ middleware.use(lambda { Rails.application.metal_loader.build_middleware(Rails.application.config.metals) }, :if => lambda { Rails.application.metal_loader.metals.any? })
+ middleware.use('ActionDispatch::ParamsParser')
+ middleware.use('::Rack::MethodOverride')
+ middleware.use('::ActionDispatch::Head')
+ end
end
- super
- end
-
- def config_key_regexp
- bits = config_keys.map { |n| Regexp.escape(n.to_s) }.join('|')
- /^(#{bits})(?:=)?$/
- end
-
- def config_keys
- ([ :active_support, :action_view ] +
- Railtie.plugin_names).map { |n| n.to_s }.uniq
- end
- end
-
- class Configuration < Railtie::Configuration
- attr_accessor :after_initialize_blocks, :cache_classes, :colorize_logging,
- :consider_all_requests_local, :dependency_loading, :filter_parameters,
- :load_once_paths, :logger, :metals, :plugins,
- :preload_frameworks, :reload_plugins, :serve_static_assets,
- :time_zone, :whiny_nils
-
- attr_writer :cache_store, :controller_paths,
- :database_configuration_file, :eager_load_paths,
- :i18n, :load_paths, :log_level, :log_path, :paths,
- :routes_configuration_file, :view_path
-
- def initialize(base = nil)
- super
- @load_once_paths = []
- @after_initialize_blocks = []
- @filter_parameters = []
- @dependency_loading = true
- @serve_static_assets = true
- end
-
- def after_initialize(&blk)
- @after_initialize_blocks << blk if blk
- end
-
- def root
- @root ||= begin
- call_stack = caller.map { |p| p.split(':').first }
- root_path = call_stack.detect { |p| p !~ %r[railties/lib/rails|rack/lib/rack] }
- root_path = File.dirname(root_path)
-
- while root_path && File.directory?(root_path) && !File.exist?("#{root_path}/config.ru")
- parent = File.dirname(root_path)
- root_path = parent != root_path && parent
+ # Holds generators configuration:
+ #
+ # config.generators do |g|
+ # g.orm :datamapper, :migration => true
+ # g.template_engine :haml
+ # g.test_framework :rspec
+ # end
+ #
+ # If you want to disable color in console, do:
+ #
+ # config.generators.colorize_logging = false
+ #
+ def generators
+ @@generators ||= Rails::Configuration::Generators.new
+ if block_given?
+ yield @@generators
+ else
+ @@generators
end
-
- root = File.exist?("#{root_path}/config.ru") ? root_path : Dir.pwd
-
- RUBY_PLATFORM =~ /(:?mswin|mingw)/ ?
- Pathname.new(root).expand_path :
- Pathname.new(root).realpath
end
- end
-
- def root=(root)
- @root = Pathname.new(root).expand_path
- end
- def paths
- @paths ||= begin
- paths = Rails::Application::Root.new(root)
- paths.app "app", :load_path => true
- paths.app.metals "app/metal", :eager_load => true
- paths.app.models "app/models", :eager_load => true
- paths.app.controllers "app/controllers", builtin_directories, :eager_load => true
- paths.app.helpers "app/helpers", :eager_load => true
- paths.app.services "app/services", :load_path => true
- paths.lib "lib", :load_path => true
- paths.vendor "vendor", :load_path => true
- paths.vendor.plugins "vendor/plugins"
- paths.tmp "tmp"
- paths.tmp.cache "tmp/cache"
- paths.config "config"
- paths.config.locales "config/locales"
- paths.config.environments "config/environments", :glob => "#{Rails.env}.rb"
- paths
+ def after_initialize_blocks
+ @@after_initialize_blocks ||= []
end
- end
-
- def frameworks(*args)
- raise "config.frameworks in no longer supported. See the generated " \
- "config/boot.rb for steps on how to limit the frameworks that " \
- "will be loaded"
- end
- alias frameworks= frameworks
-
- # Enable threaded mode. Allows concurrent requests to controller actions and
- # multiple database connections. Also disables automatic dependency loading
- # after boot, and disables reloading code on every request, as these are
- # fundamentally incompatible with thread safety.
- def threadsafe!
- self.preload_frameworks = true
- self.cache_classes = true
- self.dependency_loading = false
- if respond_to?(:action_controller)
- action_controller.allow_concurrency = true
+ def after_initialize(&blk)
+ after_initialize_blocks << blk if blk
end
- self
- end
-
- # Loads and returns the contents of the #database_configuration_file. The
- # contents of the file are processed via ERB before being sent through
- # YAML::load.
- def database_configuration
- require 'erb'
- YAML::load(ERB.new(IO.read(database_configuration_file)).result)
- end
-
- def routes_configuration_file
- @routes_configuration_file ||= File.join(root, 'config', 'routes.rb')
- end
-
- def builtin_routes_configuration_file
- @builtin_routes_configuration_file ||= File.join(RAILTIES_PATH, 'builtin', 'routes.rb')
- end
- def controller_paths
- @controller_paths ||= begin
- paths = [File.join(root, 'app', 'controllers')]
- paths.concat builtin_directories
- paths
+ def to_prepare_blocks
+ @@to_prepare_blocks ||= []
end
- end
- def cache_store
- @cache_store ||= begin
- if File.exist?("#{root}/tmp/cache/")
- [ :file_store, "#{root}/tmp/cache/" ]
- else
- :memory_store
- end
+ def to_prepare(&blk)
+ to_prepare_blocks << blk if blk
end
- end
-
- def database_configuration_file
- @database_configuration_file ||= File.join(root, 'config', 'database.yml')
- end
-
- def view_path
- @view_path ||= File.join(root, 'app', 'views')
- end
-
- def eager_load_paths
- @eager_load_paths ||= ["#{root}/app/*"]
- end
- def load_paths
- @load_paths ||= begin
- paths = []
-
- # Add the old mock paths only if the directories exists
- paths.concat(Dir["#{root}/test/mocks/#{Rails.env}"]) if File.exists?("#{root}/test/mocks/#{Rails.env}")
-
- # Followed by the standard includes.
- paths.concat %w(
- app
- app/*
- lib
- vendor
- ).map { |dir| "#{root}/#{dir}" }
-
- paths.concat builtin_directories
+ def respond_to?(name)
+ super || name.to_s =~ config_key_regexp
end
- end
- def builtin_directories
- # Include builtins only in the development environment.
- Rails.env.development? ? Dir["#{RAILTIES_PATH}/builtin/*/"] : []
- end
+ private
- def log_path
- @log_path ||= File.join(root, 'log', "#{Rails.env}.log")
- end
-
- def log_level
- @log_level ||= Rails.env.production? ? :info : :debug
- end
-
- def time_zone
- @time_zone ||= "UTC"
- end
-
- def i18n
- @i18n ||= begin
- i18n = ActiveSupport::OrderedOptions.new
- i18n.load_path = []
-
- if File.exist?(File.join(root, 'config', 'locales'))
- i18n.load_path << Dir[File.join(root, 'config', 'locales', '*.{rb,yml}')]
- i18n.load_path.flatten!
+ def method_missing(name, *args, &blk)
+ if name.to_s =~ config_key_regexp
+ return $2 == '=' ? options[$1] = args.first : options[$1]
end
-
- i18n
+ super
end
- end
- def environment_path
- "#{root}/config/environments/#{Rails.env}.rb"
- end
+ def config_key_regexp
+ bits = config_keys.map { |n| Regexp.escape(n.to_s) }.join('|')
+ /^(#{bits})(?:=)?$/
+ end
- # Holds generators configuration:
- #
- # config.generators do |g|
- # g.orm :datamapper, :migration => true
- # g.template_engine :haml
- # g.test_framework :rspec
- # end
- #
- # If you want to disable color in console, do:
- #
- # config.generators.colorize_logging = false
- #
- def generators
- @generators ||= Generators.new
- if block_given?
- yield @generators
- else
- @generators
+ def config_keys
+ (Railtie.railtie_names + Engine.engine_names).map { |n| n.to_s }.uniq
end
- end
- # Allow Notifications queue to be modified or add subscriptions:
- #
- # config.notifications.queue = MyNewQueue.new
- #
- # config.notifications.subscribe /action_dispatch.show_exception/ do |*args|
- # ExceptionDeliver.deliver_exception(args)
- # end
- #
- def notifications
- ActiveSupport::Notifications
+ def options
+ @@options ||= Hash.new { |h,k| h[k] = ActiveSupport::OrderedOptions.new }
+ end
end
class Generators #:nodoc:
@@ -303,6 +99,8 @@ module Rails
def method_missing(method, *args)
method = method.to_s.sub(/=$/, '').to_sym
+ return @options[method] if args.empty?
+
if method == :rails
namespace, configuration = :rails, args.shift
elsif args.first.is_a?(Hash)
@@ -319,5 +117,74 @@ module Rails
end
end
end
+
+ module Deprecated
+ def frameworks(*args)
+ raise "config.frameworks in no longer supported. See the generated " \
+ "config/boot.rb for steps on how to limit the frameworks that " \
+ "will be loaded"
+ end
+ alias :frameworks= :frameworks
+
+ def view_path=(value)
+ ActiveSupport::Deprecation.warn "config.view_path= is deprecated, " <<
+ "please do config.paths.app.views= instead", caller
+ paths.app.views = value
+ end
+
+ def view_path
+ ActiveSupport::Deprecation.warn "config.view_path is deprecated, " <<
+ "please do config.paths.app.views instead", caller
+ paths.app.views.to_a.first
+ end
+
+ def routes_configuration_file=(value)
+ ActiveSupport::Deprecation.warn "config.routes_configuration_file= is deprecated, " <<
+ "please do config.paths.config.routes= instead", caller
+ paths.config.routes = value
+ end
+
+ def routes_configuration_file
+ ActiveSupport::Deprecation.warn "config.routes_configuration_file is deprecated, " <<
+ "please do config.paths.config.routes instead", caller
+ paths.config.routes.to_a.first
+ end
+
+ def database_configuration_file=(value)
+ ActiveSupport::Deprecation.warn "config.database_configuration_file= is deprecated, " <<
+ "please do config.paths.config.database= instead", caller
+ paths.config.database = value
+ end
+
+ def database_configuration_file
+ ActiveSupport::Deprecation.warn "config.database_configuration_file is deprecated, " <<
+ "please do config.paths.config.database instead", caller
+ paths.config.database.to_a.first
+ end
+
+ def log_path=(value)
+ ActiveSupport::Deprecation.warn "config.log_path= is deprecated, " <<
+ "please do config.paths.log= instead", caller
+ paths.config.log = value
+ end
+
+ def log_path
+ ActiveSupport::Deprecation.warn "config.log_path is deprecated, " <<
+ "please do config.paths.log instead", caller
+ paths.config.log.to_a.first
+ end
+
+ def controller_paths=(value)
+ ActiveSupport::Deprecation.warn "config.controller_paths= is deprecated, " <<
+ "please do config.paths.app.controllers= instead", caller
+ paths.app.controllers = value
+ end
+
+ def controller_paths
+ ActiveSupport::Deprecation.warn "config.controller_paths is deprecated, " <<
+ "please do config.paths.app.controllers instead", caller
+ paths.app.controllers.to_a.uniq
+ end
+ end
end
end
diff --git a/railties/lib/rails/console_app.rb b/railties/lib/rails/console/app.rb
index 2c4a7a51e8..7e8fd027e6 100644
--- a/railties/lib/rails/console_app.rb
+++ b/railties/lib/rails/console/app.rb
@@ -23,10 +23,11 @@ def new_session
session
end
-#reloads the environment
-def reload!
- puts "Reloading..."
- ActionDispatch::Callbacks.new(lambda {}, true)
- Rails.application.reload_routes!
+# reloads the environment
+def reload!(print=true)
+ puts "Reloading..." if print
+ ActionDispatch::Callbacks.new(lambda {}, false)
true
end
+
+reload!(false)
diff --git a/railties/lib/rails/console_with_helpers.rb b/railties/lib/rails/console/helpers.rb
index 039db667c4..039db667c4 100644
--- a/railties/lib/rails/console_with_helpers.rb
+++ b/railties/lib/rails/console/helpers.rb
diff --git a/railties/lib/rails/console_sandbox.rb b/railties/lib/rails/console/sandbox.rb
index 65a3d68619..65a3d68619 100644
--- a/railties/lib/rails/console_sandbox.rb
+++ b/railties/lib/rails/console/sandbox.rb
diff --git a/railties/lib/rails/engine.rb b/railties/lib/rails/engine.rb
new file mode 100644
index 0000000000..33d62c8155
--- /dev/null
+++ b/railties/lib/rails/engine.rb
@@ -0,0 +1,130 @@
+require 'active_support/core_ext/module/delegation'
+require 'rails/railtie'
+
+module Rails
+ class Engine < Railtie
+ autoload :Configurable, "rails/engine/configurable"
+ autoload :Configuration, "rails/engine/configuration"
+
+ class << self
+ attr_accessor :called_from
+
+ alias :engine_name :railtie_name
+ alias :engine_names :railtie_names
+
+ def inherited(base)
+ unless abstract_railtie?(base)
+ base.called_from = begin
+ call_stack = caller.map { |p| p.split(':').first }
+ File.dirname(call_stack.detect { |p| p !~ %r[railties/lib/rails|rack/lib/rack] })
+ end
+ end
+
+ super
+ end
+
+ def find_root_with_flag(flag, default=nil)
+ root_path = self.called_from
+
+ while root_path && File.directory?(root_path) && !File.exist?("#{root_path}/#{flag}")
+ parent = File.dirname(root_path)
+ root_path = parent != root_path && parent
+ end
+
+ root = File.exist?("#{root_path}/#{flag}") ? root_path : default
+ raise "Could not find root path for #{self}" unless root
+
+ RUBY_PLATFORM =~ /(:?mswin|mingw)/ ?
+ Pathname.new(root).expand_path : Pathname.new(root).realpath
+ end
+ end
+
+ delegate :middleware, :paths, :root, :to => :config
+
+ def load_tasks
+ super
+ config.paths.lib.tasks.to_a.sort.each { |ext| load(ext) }
+ end
+
+ # Add configured load paths to ruby load paths and remove duplicates.
+ initializer :set_load_path, :before => :bootstrap_load_path do
+ config.load_paths.reverse_each do |path|
+ $LOAD_PATH.unshift(path) if File.directory?(path)
+ end
+ $LOAD_PATH.uniq!
+ end
+
+ # Set the paths from which Rails will automatically load source files,
+ # and the load_once paths.
+ initializer :set_autoload_paths, :before => :bootstrap_load_path do |app|
+ ActiveSupport::Dependencies.load_paths.unshift(*config.load_paths)
+
+ if reloadable?(app)
+ ActiveSupport::Dependencies.load_once_paths.unshift(*config.load_once_paths)
+ else
+ ActiveSupport::Dependencies.load_once_paths.unshift(*config.load_paths)
+ end
+
+ # Freeze so future modifications will fail rather than do nothing mysteriously
+ config.load_paths.freeze
+ config.load_once_paths.freeze
+ end
+
+ initializer :add_routing_paths do |app|
+ paths.config.routes.to_a.each do |route|
+ app.routes_reloader.paths.unshift(route) if File.exists?(route)
+ end
+ end
+
+ initializer :add_routing_namespaces do |app|
+ paths.app.controllers.to_a.each do |load_path|
+ load_path = File.expand_path(load_path)
+ Dir["#{load_path}/*/*_controller.rb"].collect do |path|
+ namespace = File.dirname(path).sub(/#{load_path}\/?/, '')
+ app.routes.controller_namespaces << namespace unless namespace.empty?
+ end
+ end
+ end
+
+ # I18n load paths are a special case since the ones added
+ # later have higher priority.
+ initializer :add_locales do
+ config.i18n.engines_load_path.concat(paths.config.locales.to_a)
+ end
+
+ initializer :add_view_paths do
+ views = paths.app.views.to_a
+ ActionController::Base.view_paths.unshift(*views) if defined?(ActionController)
+ ActionMailer::Base.view_paths.unshift(*views) if defined?(ActionMailer)
+ end
+
+ initializer :add_metals do |app|
+ app.metal_loader.paths.unshift(*paths.app.metals.to_a)
+ end
+
+ initializer :load_application_initializers do
+ paths.config.initializers.to_a.sort.each do |initializer|
+ load(initializer)
+ end
+ end
+
+ initializer :load_application_classes do |app|
+ next if $rails_rake_task
+
+ if app.config.cache_classes
+ config.eager_load_paths.each do |load_path|
+ matcher = /\A#{Regexp.escape(load_path)}\/(.*)\.rb\Z/
+ Dir.glob("#{load_path}/**/*.rb").sort.each do |file|
+ require_dependency file.sub(matcher, '\1')
+ end
+ end
+ end
+ end
+
+ protected
+
+ def reloadable?(app)
+ app.config.reload_engines
+ end
+ end
+end \ No newline at end of file
diff --git a/railties/lib/rails/engine/configurable.rb b/railties/lib/rails/engine/configurable.rb
new file mode 100644
index 0000000000..9a370f0abb
--- /dev/null
+++ b/railties/lib/rails/engine/configurable.rb
@@ -0,0 +1,25 @@
+module Rails
+ class Engine
+ module Configurable
+ def self.included(base)
+ base.extend ClassMethods
+ end
+
+ module ClassMethods
+ delegate :middleware, :root, :paths, :to => :config
+
+ def config
+ @config ||= Engine::Configuration.new(find_root_with_flag("lib"))
+ end
+
+ def inherited(base)
+ raise "You cannot inherit from a Rails::Engine child"
+ end
+ end
+
+ def config
+ self.class.config
+ end
+ end
+ end
+end \ No newline at end of file
diff --git a/railties/lib/rails/engine/configuration.rb b/railties/lib/rails/engine/configuration.rb
new file mode 100644
index 0000000000..7d6de91430
--- /dev/null
+++ b/railties/lib/rails/engine/configuration.rb
@@ -0,0 +1,49 @@
+require 'rails/railtie/configuration'
+
+module Rails
+ class Engine
+ class Configuration < ::Rails::Railtie::Configuration
+ attr_reader :root
+ attr_writer :eager_load_paths, :load_once_paths, :load_paths
+
+ def initialize(root=nil)
+ @root = root
+ end
+
+ def paths
+ @paths ||= begin
+ paths = Rails::Paths::Root.new(@root)
+ paths.app "app", :eager_load => true, :glob => "*"
+ paths.app.controllers "app/controllers", :eager_load => true
+ paths.app.helpers "app/helpers", :eager_load => true
+ paths.app.models "app/models", :eager_load => true
+ paths.app.metals "app/metal"
+ paths.app.views "app/views"
+ paths.lib "lib", :load_path => true
+ paths.lib.tasks "lib/tasks", :glob => "**/*.rake"
+ paths.config "config"
+ paths.config.initializers "config/initializers", :glob => "**/*.rb"
+ paths.config.locales "config/locales", :glob => "*.{rb,yml}"
+ paths.config.routes "config/routes.rb"
+ paths
+ end
+ end
+
+ def root=(value)
+ @root = paths.path = Pathname.new(value).expand_path
+ end
+
+ def eager_load_paths
+ @eager_load_paths ||= paths.eager_load
+ end
+
+ def load_once_paths
+ @eager_load_paths ||= paths.load_once
+ end
+
+ def load_paths
+ @load_paths ||= paths.load_paths
+ end
+ end
+ end
+end \ No newline at end of file
diff --git a/railties/lib/rails/generators.rb b/railties/lib/rails/generators.rb
index 83b8c74966..1271de7af9 100644
--- a/railties/lib/rails/generators.rb
+++ b/railties/lib/rails/generators.rb
@@ -38,11 +38,6 @@ module Rails
}
DEFAULT_OPTIONS = {
- :active_record => {
- :migration => true,
- :timestamps => true
- },
-
:erb => {
:layout => true
},
@@ -51,20 +46,15 @@ module Rails
:force_plural => false,
:helper => true,
:layout => true,
- :orm => :active_record,
- :integration_tool => :test_unit,
- :performance_tool => :test_unit,
+ :orm => nil,
+ :integration_tool => nil,
+ :performance_tool => nil,
:resource_controller => :controller,
:scaffold_controller => :scaffold_controller,
:singleton => false,
:stylesheets => true,
- :template_engine => :erb,
- :test_framework => :test_unit
- },
-
- :test_unit => {
- :fixture => true,
- :fixture_replacement => nil
+ :test_framework => nil,
+ :template_engine => :erb
},
:plugin => {
@@ -200,6 +190,7 @@ module Rails
# Print Rails defaults first.
rails = groups.delete("rails")
rails.map! { |n| n.sub(/^rails:/, '') }
+ rails.delete("app")
print_list("rails", rails)
groups.sort.each { |b, n| print_list(b, n) }
diff --git a/railties/lib/rails/generators/named_base.rb b/railties/lib/rails/generators/named_base.rb
index 3e851bf888..12e918731e 100644
--- a/railties/lib/rails/generators/named_base.rb
+++ b/railties/lib/rails/generators/named_base.rb
@@ -6,17 +6,9 @@ module Rails
class NamedBase < Base
argument :name, :type => :string
- no_tasks {
- attr_reader :class_name, :singular_name, :plural_name, :table_name,
- :class_path, :file_path, :class_nesting_depth
-
- alias :file_name :singular_name
- }
-
def initialize(args, *options) #:nodoc:
# Unfreeze name in case it's given as a frozen string
args[0] = args[0].dup if args[0].is_a?(String) && args[0].frozen?
-
super
assign_names!(self.name)
parse_attributes! if respond_to?(:attributes)
@@ -24,28 +16,48 @@ module Rails
protected
- def assign_names!(given_name) #:nodoc:
- base_name, @class_path, @file_path, class_nesting, @class_nesting_depth = extract_modules(given_name)
- class_name_without_nesting, @singular_name, @plural_name = inflect_names(base_name)
+ attr_reader :class_path, :file_name
+ alias :singular_name :file_name
- @table_name = if pluralize_table_names?
- plural_name
- else
- singular_name
+ def file_path
+ @file_path ||= (class_path + [file_name]).join('/')
+ end
+
+ def class_name
+ @class_name ||= (class_path + [file_name]).map!{ |m| m.camelize }.join('::')
+ end
+
+ def plural_name
+ @plural_name ||= singular_name.pluralize
+ end
+
+ def i18n_scope
+ @i18n_scope ||= file_path.gsub('/', '.')
+ end
+
+ def table_name
+ @table_name ||= begin
+ base = pluralize_table_names? ? plural_name : singular_name
+ (class_path + [base]).join('_')
end
+ end
- if class_nesting.empty?
- @class_name = class_name_without_nesting
+ # Tries to retrieve the application name or simple return application.
+ def application_name
+ if defined?(Rails) && Rails.application
+ Rails.application.class.name.split('::').first.underscore
else
- @table_name = class_nesting.underscore << "_" << @table_name
- @class_name = "#{class_nesting}::#{class_name_without_nesting}"
+ "application"
end
+ end
- @table_name.gsub!('/', '_')
+ def assign_names!(name) #:nodoc:
+ @class_path = name.include?('/') ? name.split('/') : name.split('::')
+ @class_path.map! { |m| m.underscore }
+ @file_name = @class_path.pop
end
- # Convert attributes hash into an array with GeneratedAttribute objects.
- #
+ # Convert attributes array into GeneratedAttribute objects.
def parse_attributes! #:nodoc:
self.attributes = (attributes || []).map do |key_value|
name, type = key_value.split(':')
@@ -53,29 +65,6 @@ module Rails
end
end
- # Extract modules from filesystem-style or ruby-style path. Both
- # good/fun/stuff and Good::Fun::Stuff produce the same results.
- #
- def extract_modules(name) #:nodoc:
- modules = name.include?('/') ? name.split('/') : name.split('::')
- name = modules.pop
- path = modules.map { |m| m.underscore }
-
- file_path = (path + [name.underscore]).join('/')
- nesting = modules.map { |m| m.camelize }.join('::')
-
- [name, path, file_path, nesting, modules.size]
- end
-
- # Receives name and return camelized, underscored and pluralized names.
- #
- def inflect_names(name) #:nodoc:
- camel = name.camelize
- under = camel.underscore
- plural = under.pluralize
- [camel, under, plural]
- end
-
def pluralize_table_names?
!defined?(ActiveRecord::Base) || ActiveRecord::Base.pluralize_table_names
end
diff --git a/railties/lib/rails/generators/resource_helpers.rb b/railties/lib/rails/generators/resource_helpers.rb
index 7e00a222ed..3a98a8f9c1 100644
--- a/railties/lib/rails/generators/resource_helpers.rb
+++ b/railties/lib/rails/generators/resource_helpers.rb
@@ -9,14 +9,7 @@ module Rails
mattr_accessor :skip_warn
def self.included(base) #:nodoc:
- base.class_eval do
- class_option :force_plural, :type => :boolean, :desc => "Forces the use of a plural ModelName"
-
- no_tasks {
- attr_reader :controller_name, :controller_class_name, :controller_file_name,
- :controller_class_path, :controller_file_path
- }
- end
+ base.class_option :force_plural, :type => :boolean, :desc => "Forces the use of a plural ModelName"
end
# Set controller variables on initialization.
@@ -29,29 +22,40 @@ module Rails
say "Plural version of the model detected, using singularized version. Override with --force-plural."
ResourceHelpers.skip_warn = true
end
-
name.replace name.singularize
- assign_names!(self.name)
+ assign_names!(name)
end
@controller_name = name.pluralize
+ end
- base_name, @controller_class_path, @controller_file_path, class_nesting, class_nesting_depth = extract_modules(@controller_name)
- class_name_without_nesting, @controller_file_name, controller_plural_name = inflect_names(base_name)
+ protected
+
+ attr_reader :controller_name
- @controller_class_name = if class_nesting.empty?
- class_name_without_nesting
- else
- "#{class_nesting}::#{class_name_without_nesting}"
+ def controller_class_path
+ @class_path
end
- end
- protected
+ def controller_file_name
+ @controller_file_name ||= file_name.pluralize
+ end
+
+ def controller_file_path
+ @controller_file_path ||= (controller_class_path + [controller_file_name]).join('/')
+ end
+
+ def controller_class_name
+ @controller_class_name ||= (controller_class_path + [controller_file_name]).map!{ |m| m.camelize }.join('::')
+ end
+
+ def controller_i18n_scope
+ @controller_i18n_scope ||= controller_file_path.gsub('/', '.')
+ end
# Loads the ORM::Generators::ActiveModel class. This class is responsable
# to tell scaffold entities how to generate an specific method for the
# ORM. Check Rails::Generators::ActiveModel for more information.
- #
def orm_class
@orm_class ||= begin
# Raise an error if the class_option :orm was not defined.
@@ -68,7 +72,6 @@ module Rails
end
# Initialize ORM::Generators::ActiveModel to access instance methods.
- #
def orm_instance(name=file_name)
@orm_instance ||= @orm_class.new(name)
end
diff --git a/railties/lib/rails/initializable.rb b/railties/lib/rails/initializable.rb
index 8fcb254590..d91f67823f 100644
--- a/railties/lib/rails/initializable.rb
+++ b/railties/lib/rails/initializable.rb
@@ -19,12 +19,6 @@ module Rails
@options[:after]
end
- def global
- @options[:global]
- end
-
- alias global? global
-
def run(*args)
@context.instance_exec(*args, &block)
end
@@ -70,10 +64,7 @@ module Rails
end
def initializers
- @initializers ||= begin
- initializers = self.class.initializers_for(:instance)
- Collection.new(initializers.map { |i| i.bind(self) })
- end
+ @initializers ||= self.class.initializers_for(self)
end
module ClassMethods
@@ -81,26 +72,27 @@ module Rails
@initializers ||= []
end
- def initializers_for(scope = :global)
+ def initializers_chain
initializers = Collection.new
ancestors.reverse_each do |klass|
next unless klass.respond_to?(:initializers)
- initializers = initializers + klass.initializers.select { |i|
- (scope == :global) == !!i.global?
- }
+ initializers = initializers + klass.initializers
end
initializers
end
+ def initializers_for(binding)
+ Collection.new(initializers_chain.map { |i| i.bind(binding) })
+ end
+
def initializer(name, opts = {}, &blk)
raise ArgumentError, "A block must be passed when defining an initializer" unless blk
- @initializers ||= []
- @initializers << Initializer.new(name, nil, opts, &blk)
+ initializers << Initializer.new(name, nil, opts, &blk)
end
def run_initializers(*args)
return if @ran
- initializers_for(:global).each do |initializer|
+ initializers_chain.each do |initializer|
instance_exec(*args, &initializer.block)
end
@ran = true
diff --git a/railties/lib/rails/paths.rb b/railties/lib/rails/paths.rb
index b3d105d8c7..55874813da 100644
--- a/railties/lib/rails/paths.rb
+++ b/railties/lib/rails/paths.rb
@@ -1,7 +1,7 @@
require 'set'
module Rails
- class Application
+ module Paths
module PathParent
def method_missing(id, *args)
name = id.to_s
@@ -31,27 +31,21 @@ module Rails
@all_paths = []
end
- def load_once
- all_paths.map { |path| path.paths if path.load_once? }.compact.flatten.uniq
- end
-
- def eager_load
- all_paths.map { |path| path.paths if path.eager_load? }.compact.flatten.uniq
- end
-
def all_paths
@all_paths.uniq!
@all_paths
end
- def load_paths
- all_paths.map { |path| path.paths if path.load_path? }.compact.flatten.uniq
+ def load_once
+ filter { |path| path.paths if path.load_once? }
end
- def add_to_load_path
- load_paths.reverse_each do |path|
- $LOAD_PATH.unshift(path) if File.directory?(path)
- end
+ def eager_load
+ filter { |path| path.paths if path.eager_load? }
+ end
+
+ def load_paths
+ filter { |path| path.paths if path.load_path? }
end
def push(*)
@@ -61,6 +55,12 @@ module Rails
alias unshift push
alias << push
alias concat push
+
+ protected
+
+ def filter(&block)
+ all_paths.map(&block).compact.flatten.uniq.select { |p| File.exists?(p) }
+ end
end
class Path
@@ -74,11 +74,11 @@ module Rails
@children = {}
@root = root
@paths = paths.flatten
- @glob = @options[:glob] || "**/*.rb"
+ @glob = @options.delete(:glob)
@load_once = @options[:load_once]
@eager_load = @options[:eager_load]
- @load_path = @options[:load_path] || @eager_load
+ @load_path = @options[:load_path] || @eager_load || @load_once
@root.all_paths << self
end
@@ -103,6 +103,7 @@ module Rails
def load_once!
@load_once = true
+ @load_path = true
end
def load_once?
@@ -128,10 +129,13 @@ module Rails
def paths
raise "You need to set a path root" unless @root.path
-
- @paths.map do |path|
- path.index('/') == 0 ? path : File.expand_path(File.join(@root.path, path))
+ result = @paths.map do |p|
+ path = File.expand_path(p, @root.path)
+ @glob ? Dir[File.join(path, @glob)] : path
end
+ result.flatten!
+ result.uniq!
+ result
end
alias to_a paths
diff --git a/railties/lib/rails/plugin.rb b/railties/lib/rails/plugin.rb
index c3b81bcd3e..881c97f02d 100644
--- a/railties/lib/rails/plugin.rb
+++ b/railties/lib/rails/plugin.rb
@@ -1,5 +1,11 @@
+require 'rails/engine'
+
module Rails
- class Plugin < Railtie
+ class Plugin < Engine
+ def self.inherited(base)
+ raise "You cannot inherit from Rails::Plugin"
+ end
+
def self.all(list, paths)
plugins = []
paths.each do |path|
@@ -17,53 +23,42 @@ module Rails
attr_reader :name, :path
- def initialize(path)
- @name = File.basename(path).to_sym
- @path = path
- end
+ def load_tasks
+ super
+ extra_tasks = Dir["#{root}/{tasks,rails/tasks}/**/*.rake"]
- def load_paths
- Dir["#{path}/{lib}", "#{path}/app/{models,controllers,helpers}"]
+ unless extra_tasks.empty?
+ ActiveSupport::Deprecation.warn "Having rake tasks in PLUGIN_PATH/tasks or " <<
+ "PLUGIN_PATH/rails/tasks is deprecated. Use to PLUGIN_PATH/lib/tasks instead"
+ extra_tasks.sort.each { |ext| load(ext) }
+ end
end
- def load_tasks
- Dir["#{path}/{tasks,lib/tasks,rails/tasks}/**/*.rake"].sort.each { |ext| load ext }
+ def initialize(root)
+ @name = File.basename(root).to_sym
+ config.root = root
end
- initializer :add_to_load_path, :after => :set_autoload_paths do |app|
- load_paths.each do |path|
- $LOAD_PATH << path
- require "active_support/dependencies"
-
- ActiveSupport::Dependencies.load_paths << path
-
- unless app.config.reload_plugins
- ActiveSupport::Dependencies.load_once_paths << path
- end
- end
+ def config
+ @config ||= Engine::Configuration.new
end
- initializer :load_init_rb, :before => :load_application_initializers do |app|
- file = "#{@path}/init.rb"
+ initializer :load_init_rb do |app|
+ file = Dir["#{root}/{rails/init,init}.rb"].first
config = app.config
- eval File.read(file), binding, file if File.file?(file)
+ eval(File.read(file), binding, file) if file && File.file?(file)
end
- initializer :add_view_paths, :after => :initialize_framework_views do
- plugin_views = "#{path}/app/views"
- if File.directory?(plugin_views)
- ActionController::Base.view_paths.concat([plugin_views]) if defined? ActionController
- ActionMailer::Base.view_paths.concat([plugin_views]) if defined? ActionMailer
+ initializer :sanity_check_railties_collision do
+ if Engine.subclasses.map { |k| k.root.to_s }.include?(root.to_s)
+ raise "\"#{name}\" is a Railtie/Engine and cannot be installed as plugin"
end
end
- # TODO Isn't it supposed to be :after => "action_controller.initialize_routing" ?
- initializer :add_routing_file, :after => :initialize_routing do |app|
- routing_file = "#{path}/config/routes.rb"
- if File.exist?(routing_file)
- app.route_configuration_files << routing_file
- app.reload_routes!
- end
+ protected
+
+ def reloadable?(app)
+ app.config.reload_plugins
end
end
end
diff --git a/railties/lib/rails/rack.rb b/railties/lib/rails/rack.rb
index 4bc0c2c88b..1f20ceae44 100644
--- a/railties/lib/rails/rack.rb
+++ b/railties/lib/rails/rack.rb
@@ -3,7 +3,6 @@ module Rails
autoload :Debugger, "rails/rack/debugger"
autoload :Logger, "rails/rack/logger"
autoload :LogTailer, "rails/rack/log_tailer"
- autoload :Metal, "rails/rack/metal"
autoload :Static, "rails/rack/static"
end
end
diff --git a/railties/lib/rails/rack/logger.rb b/railties/lib/rails/rack/logger.rb
index 91a613092f..de21fb4f10 100644
--- a/railties/lib/rails/rack/logger.rb
+++ b/railties/lib/rails/rack/logger.rb
@@ -9,27 +9,23 @@ module Rails
end
def call(env)
- @env = env
- before_dispatch
- result = @app.call(@env)
- after_dispatch
- result
+ before_dispatch(env)
+ @app.call(env)
+ ensure
+ after_dispatch(env)
end
protected
- def request
- @request ||= ActionDispatch::Request.new(@env)
- end
-
- def before_dispatch
+ def before_dispatch(env)
+ request = ActionDispatch::Request.new(env)
path = request.request_uri.inspect rescue "unknown"
info "\n\nStarted #{request.method.to_s.upcase} #{path} " <<
"for #{request.remote_ip} at #{Time.now.to_s(:db)}"
end
- def after_dispatch
+ def after_dispatch(env)
Rails::Subscriber.flush_all!
end
diff --git a/railties/lib/rails/rack/metal.rb b/railties/lib/rails/rack/metal.rb
deleted file mode 100644
index 565f95d7c4..0000000000
--- a/railties/lib/rails/rack/metal.rb
+++ /dev/null
@@ -1,26 +0,0 @@
-require 'action_dispatch'
-
-module Rails
- module Rack
- class Metal
- def initialize(metal_roots, metals=nil)
- load_list = metals || Dir["{#{metal_roots.join(",")}}/**/*.rb"]
-
- @metals = load_list.map { |metal|
- metal = File.basename(metal, '.rb')
- require_dependency metal
- metal.camelize.constantize
- }.compact
- end
-
- def new(app)
- ActionDispatch::Cascade.new(@metals, app)
- end
-
- def name
- ActionDispatch::Cascade.name
- end
- alias_method :to_s, :name
- end
- end
-end
diff --git a/railties/lib/rails/railtie.rb b/railties/lib/rails/railtie.rb
index 611688cef1..2dc2ba1002 100644
--- a/railties/lib/rails/railtie.rb
+++ b/railties/lib/rails/railtie.rb
@@ -1,3 +1,6 @@
+require 'rails/initializable'
+require 'rails/configuration'
+
module Rails
# Railtie is the core of the Rails Framework and provides all the hooks and
# methods you need to link your plugin into Rails.
@@ -108,52 +111,56 @@ module Rails
# gem "my_gem", :require_as => ["my_gem", "my_gem/railtie"]
#
class Railtie
+ autoload :Configurable, "rails/railtie/configurable"
+ autoload :Configuration, "rails/railtie/configuration"
+
include Initializable
- # Pass in the name of your plugin. This is passed in as an underscored symbol.
- #
- # module MyPlugin
- # class Railtie < Rails::Railtie
- # plugin_name :my_plugin
- # end
- # end
- def self.plugin_name(plugin_name = nil)
- @plugin_name ||= name.demodulize.underscore
- @plugin_name = plugin_name if plugin_name
- @plugin_name
- end
+ ABSTRACT_RAILTIES = %w(Rails::Plugin Rails::Engine Rails::Application)
- def self.inherited(klass)
- @plugins ||= []
- @plugins << klass unless klass == Plugin
- end
+ class << self
+ def subclasses
+ @subclasses ||= []
+ end
- def self.plugins
- @plugins
- end
+ def inherited(base)
+ unless abstract_railtie?(base)
+ base.send(:include, self::Configurable)
+ subclasses << base
+ end
+ end
- def self.plugin_names
- plugins.map { |p| p.plugin_name }
- end
+ def railtie_name(railtie_name = nil)
+ @railtie_name ||= name.demodulize.underscore
+ @railtie_name = railtie_name if railtie_name
+ @railtie_name
+ end
- def self.config
- Configuration.default
- end
+ def railtie_names
+ subclasses.map { |p| p.railtie_name }
+ end
- def self.subscriber(subscriber)
- Rails::Subscriber.add(plugin_name, subscriber)
- end
+ def subscriber(subscriber)
+ Rails::Subscriber.add(railtie_name, subscriber)
+ end
- def self.rake_tasks(&blk)
- @rake_tasks ||= []
- @rake_tasks << blk if blk
- @rake_tasks
- end
+ def rake_tasks(&blk)
+ @rake_tasks ||= []
+ @rake_tasks << blk if blk
+ @rake_tasks
+ end
+
+ def generators(&blk)
+ @generators ||= []
+ @generators << blk if blk
+ @generators
+ end
+
+ protected
- def self.generators(&blk)
- @generators ||= []
- @generators << blk if blk
- @generators
+ def abstract_railtie?(base)
+ ABSTRACT_RAILTIES.include?(base.name)
+ end
end
def rake_tasks
@@ -165,12 +172,10 @@ module Rails
end
def load_tasks
- return unless rake_tasks
rake_tasks.each { |blk| blk.call }
end
def load_generators
- return unless generators
generators.each { |blk| blk.call }
end
end
diff --git a/railties/lib/rails/railtie/configurable.rb b/railties/lib/rails/railtie/configurable.rb
new file mode 100644
index 0000000000..a2eb938c5a
--- /dev/null
+++ b/railties/lib/rails/railtie/configurable.rb
@@ -0,0 +1,23 @@
+module Rails
+ class Railtie
+ module Configurable
+ def self.included(base)
+ base.extend ClassMethods
+ end
+
+ module ClassMethods
+ def config
+ @config ||= Railtie::Configuration.new
+ end
+
+ def inherited(base)
+ raise "You cannot inherit from a Rails::Railtie child"
+ end
+ end
+
+ def config
+ self.class.config
+ end
+ end
+ end
+end
diff --git a/railties/lib/rails/railtie/configuration.rb b/railties/lib/rails/railtie/configuration.rb
new file mode 100644
index 0000000000..bfb43f7041
--- /dev/null
+++ b/railties/lib/rails/railtie/configuration.rb
@@ -0,0 +1,9 @@
+require 'rails/configuration'
+
+module Rails
+ class Railtie
+ class Configuration
+ include Rails::Configuration::Shared
+ end
+ end
+end \ No newline at end of file
diff --git a/railties/lib/rails/tasks.rb b/railties/lib/rails/tasks.rb
index 44c014efe8..9807000578 100644
--- a/railties/lib/rails/tasks.rb
+++ b/railties/lib/rails/tasks.rb
@@ -10,7 +10,6 @@ $VERBOSE = nil
misc
routes
statistics
- testing
tmp
).each do |task|
load "rails/tasks/#{task}.rake"
diff --git a/railties/lib/rails/tasks/documentation.rake b/railties/lib/rails/tasks/documentation.rake
index 65d0d476ba..3f49a9a720 100644
--- a/railties/lib/rails/tasks/documentation.rake
+++ b/railties/lib/rails/tasks/documentation.rake
@@ -11,35 +11,43 @@ namespace :doc do
rdoc.rdoc_files.include('lib/**/*.rb')
}
- desc "Generate documentation for the Rails framework"
+ desc 'Generate documentation for the Rails framework. Specify path with PATH="/path/to/rails"'
Rake::RDocTask.new("rails") { |rdoc|
+ path = ENV['RAILS_PATH'] || 'vendor/gems/gems'
+ version = '-3.0.pre' unless ENV['RAILS_PATH']
rdoc.rdoc_dir = 'doc/api'
rdoc.template = "#{ENV['template']}.rb" if ENV['template']
rdoc.title = "Rails Framework Documentation"
rdoc.options << '--line-numbers' << '--inline-source'
rdoc.rdoc_files.include('README')
- rdoc.rdoc_files.include('vendor/rails/railties/CHANGELOG')
- rdoc.rdoc_files.include('vendor/rails/railties/MIT-LICENSE')
- rdoc.rdoc_files.include('vendor/rails/railties/README')
- rdoc.rdoc_files.include('vendor/rails/railties/lib/{*.rb,commands/*.rb,generators/*.rb}')
- rdoc.rdoc_files.include('vendor/rails/activerecord/README')
- rdoc.rdoc_files.include('vendor/rails/activerecord/CHANGELOG')
- rdoc.rdoc_files.include('vendor/rails/activerecord/lib/active_record/**/*.rb')
- rdoc.rdoc_files.exclude('vendor/rails/activerecord/lib/active_record/vendor/*')
- rdoc.rdoc_files.include('vendor/rails/activeresource/README')
- rdoc.rdoc_files.include('vendor/rails/activeresource/CHANGELOG')
- rdoc.rdoc_files.include('vendor/rails/activeresource/lib/active_resource.rb')
- rdoc.rdoc_files.include('vendor/rails/activeresource/lib/active_resource/*')
- rdoc.rdoc_files.include('vendor/rails/actionpack/README')
- rdoc.rdoc_files.include('vendor/rails/actionpack/CHANGELOG')
- rdoc.rdoc_files.include('vendor/rails/actionpack/lib/action_controller/**/*.rb')
- rdoc.rdoc_files.include('vendor/rails/actionpack/lib/action_view/**/*.rb')
- rdoc.rdoc_files.include('vendor/rails/actionmailer/README')
- rdoc.rdoc_files.include('vendor/rails/actionmailer/CHANGELOG')
- rdoc.rdoc_files.include('vendor/rails/actionmailer/lib/action_mailer/base.rb')
- rdoc.rdoc_files.include('vendor/rails/activesupport/README')
- rdoc.rdoc_files.include('vendor/rails/activesupport/CHANGELOG')
- rdoc.rdoc_files.include('vendor/rails/activesupport/lib/active_support/**/*.rb')
+
+ %w(README CHANGELOG lib/action_mailer/base.rb).each do |file|
+ rdoc.rdoc_files.include("#{path}/actionmailer#{version}/#{file}")
+ end
+
+ %w(README CHANGELOG lib/action_controller/**/*.rb lib/action_view/**/*.rb).each do |file|
+ rdoc.rdoc_files.include("#{path}/actionpack#{version}/#{file}")
+ end
+
+ %w(README CHANGELOG lib/active_model/**/*.rb).each do |file|
+ rdoc.rdoc_files.include("#{path}/activemodel#{version}/#{file}")
+ end
+
+ %w(README CHANGELOG lib/active_record/**/*.rb).each do |file|
+ rdoc.rdoc_files.include("#{path}/activerecord#{version}/#{file}")
+ end
+
+ %w(README CHANGELOG lib/active_resource.rb lib/active_resource/*).each do |file|
+ rdoc.rdoc_files.include("#{path}/activeresource#{version}/#{file}")
+ end
+
+ %w(README CHANGELOG lib/active_support/**/*.rb).each do |file|
+ rdoc.rdoc_files.include("#{path}/activesupport#{version}/#{file}")
+ end
+
+ %w(README CHANGELOG MIT-LICENSE lib/{*.rb,commands/*.rb,generators/*.rb}).each do |file|
+ rdoc.rdoc_files.include("#{path}/railties#{version}/#{file}")
+ end
}
plugins = FileList['vendor/plugins/**'].collect { |plugin| File.basename(plugin) }
diff --git a/railties/lib/rails/tasks/middleware.rake b/railties/lib/rails/tasks/middleware.rake
index 5a5bd7a7e9..251da67c96 100644
--- a/railties/lib/rails/tasks/middleware.rake
+++ b/railties/lib/rails/tasks/middleware.rake
@@ -3,5 +3,5 @@ task :middleware => :environment do
Rails.configuration.middleware.active.each do |middleware|
puts "use #{middleware.inspect}"
end
- puts "run #{Rails.application.class.name}"
+ puts "run #{Rails::Application.instance.class.name}.routes"
end
diff --git a/railties/lib/rails/tasks/routes.rake b/railties/lib/rails/tasks/routes.rake
index 2395d73b2f..e8da72db4d 100644
--- a/railties/lib/rails/tasks/routes.rake
+++ b/railties/lib/rails/tasks/routes.rake
@@ -1,5 +1,6 @@
desc 'Print out all defined routes in match order, with names. Target specific controller with CONTROLLER=x.'
task :routes => :environment do
+ Rails::Application.reload_routes!
all_routes = ENV['CONTROLLER'] ? ActionController::Routing::Routes.routes.select { |route| route.defaults[:controller] == ENV['CONTROLLER'] } : ActionController::Routing::Routes.routes
routes = all_routes.collect do |route|
name = ActionController::Routing::Routes.named_routes.routes.index(route).to_s
diff --git a/railties/lib/rails/test_unit/railtie.rb b/railties/lib/rails/test_unit/railtie.rb
new file mode 100644
index 0000000000..f93dace9bb
--- /dev/null
+++ b/railties/lib/rails/test_unit/railtie.rb
@@ -0,0 +1,17 @@
+module Rails
+ class TestUnitRailtie < Rails::Railtie
+ railtie_name :test_unit
+
+ config.generators do |c|
+ c.test_framework :test_unit, :fixture => true,
+ :fixture_replacement => nil
+
+ c.integration_tool :test_unit
+ c.performance_tool :test_unit
+ end
+
+ rake_tasks do
+ load "rails/tasks/testing.rake"
+ end
+ end
+end \ No newline at end of file
diff --git a/railties/test/application/configuration_test.rb b/railties/test/application/configuration_test.rb
index 6968e87986..57bd797ef0 100644
--- a/railties/test/application/configuration_test.rb
+++ b/railties/test/application/configuration_test.rb
@@ -1,7 +1,7 @@
require "isolation/abstract_unit"
module ApplicationTests
- class InitializerTest < Test::Unit::TestCase
+ class ConfigurationTest < Test::Unit::TestCase
include ActiveSupport::Testing::Isolation
def new_app
@@ -12,13 +12,33 @@ module ApplicationTests
FileUtils.cp_r(app_path, new_app)
end
+ def app
+ @app ||= Rails.application
+ end
+
def setup
- FileUtils.rm_rf(new_app) if File.directory?(new_app)
build_app
boot_rails
FileUtils.rm_rf("#{app_path}/config/environments")
end
+ def teardown
+ FileUtils.rm_rf(new_app) if File.directory?(new_app)
+ end
+
+ test "Rails::Application.instance is nil until app is initialized" do
+ require 'rails'
+ assert_nil Rails::Application.instance
+ require "#{app_path}/config/environment"
+ assert_equal AppTemplate::Application.instance, Rails::Application.instance
+ end
+
+ test "Rails::Application responds to all instance methods" do
+ require "#{app_path}/config/environment"
+ assert_respond_to Rails::Application, :routes_reloader
+ assert_equal Rails::Application.routes_reloader, Rails.application.routes_reloader
+ end
+
test "the application root is set correctly" do
require "#{app_path}/config/environment"
assert_equal Pathname.new(app_path), Rails.application.root
@@ -52,21 +72,12 @@ module ApplicationTests
end
end
- test "if there's no config.active_support.bare, all of ActiveSupport is required" do
- use_frameworks []
+ test "Rails.root should be a Pathname" do
+ add_to_config <<-RUBY
+ config.root = "#{app_path}"
+ RUBY
require "#{app_path}/config/environment"
- assert_nothing_raised { [1,2,3].rand }
- end
-
- test "config.active_support.bare does not require all of ActiveSupport" do
- add_to_config "config.active_support.bare = true"
-
- use_frameworks []
-
- Dir.chdir("#{app_path}/app") do
- require "#{app_path}/config/environment"
- assert_raises(NoMethodError) { [1,2,3].rand }
- end
+ assert_instance_of Pathname, Rails.root
end
test "marking the application as threadsafe sets the correct config variables" do
@@ -129,10 +140,29 @@ module ApplicationTests
value = value.reverse if key =~ /baz/
}]
RUBY
-
+
assert_nothing_raised do
require "#{app_path}/config/application"
end
end
+
+ test "config.to_prepare is forwarded to ActionDispatch" do
+ $prepared = false
+
+ add_to_config <<-RUBY
+ config.to_prepare do
+ $prepared = true
+ end
+ RUBY
+
+ assert !$prepared
+
+ require "#{app_path}/config/environment"
+ require 'rack/test'
+ extend Rack::Test::Methods
+
+ get "/"
+ assert $prepared
+ end
end
end
diff --git a/railties/test/application/console_test.rb b/railties/test/application/console_test.rb
index e8a4a4e158..22ab60f4a0 100644
--- a/railties/test/application/console_test.rb
+++ b/railties/test/application/console_test.rb
@@ -9,8 +9,8 @@ class ConsoleTest < Test::Unit::TestCase
# Load steps taken from rails/commands/console.rb
require "#{rails_root}/config/environment"
- require 'rails/console_app'
- require 'rails/console_with_helpers'
+ require 'rails/console/app'
+ require 'rails/console/helpers'
end
def test_app_method_should_return_integration_session
diff --git a/railties/test/application/generators_test.rb b/railties/test/application/generators_test.rb
index e1e51c318c..e54edea07c 100644
--- a/railties/test/application/generators_test.rb
+++ b/railties/test/application/generators_test.rb
@@ -19,8 +19,14 @@ module ApplicationTests
yield app_const.config
end
+ def with_bare_config
+ require "rails"
+ require "rails/generators"
+ yield app_const.config
+ end
+
test "generators default values" do
- with_config do |c|
+ with_bare_config do |c|
assert_equal(true, c.generators.colorize_logging)
assert_equal({}, c.generators.aliases)
assert_equal({}, c.generators.options)
@@ -28,7 +34,7 @@ module ApplicationTests
end
test "generators set rails options" do
- with_config do |c|
+ with_bare_config do |c|
c.generators.orm = :datamapper
c.generators.test_framework = :rspec
c.generators.helper = false
@@ -75,7 +81,7 @@ module ApplicationTests
end
test "generators with hashes for options and aliases" do
- with_config do |c|
+ with_bare_config do |c|
c.generators do |g|
g.orm :datamapper, :migration => false
g.plugin :aliases => { :generator => "-g" },
@@ -92,18 +98,5 @@ module ApplicationTests
assert_equal({ :plugin => { :generator => "-g" } }, c.generators.aliases)
end
end
-
- test "generators with hashes are deep merged" do
- with_config do |c|
- c.generators do |g|
- g.orm :datamapper, :migration => false
- g.plugin :aliases => { :generator => "-g" },
- :generator => true
- end
- end
-
- assert Rails::Generators.aliases.size >= 1
- assert Rails::Generators.options.size >= 1
- end
end
end
diff --git a/railties/test/application/initializer_test.rb b/railties/test/application/initializer_test.rb
deleted file mode 100644
index 754c0f1839..0000000000
--- a/railties/test/application/initializer_test.rb
+++ /dev/null
@@ -1,185 +0,0 @@
-require "isolation/abstract_unit"
-
-module ApplicationTests
- class InitializerTest < Test::Unit::TestCase
- include ActiveSupport::Testing::Isolation
-
- def setup
- build_app
- boot_rails
- FileUtils.rm_rf "#{app_path}/config/environments"
- end
-
- test "initializing an application adds the application paths to the load path" do
- add_to_config <<-RUBY
- config.root = "#{app_path}"
- RUBY
-
- require "#{app_path}/config/environment"
- assert $:.include?("#{app_path}/app/models")
- end
-
- test "eager loading loads parent classes before children" do
- app_file "lib/zoo.rb", <<-ZOO
- class Zoo ; include ReptileHouse ; end
- ZOO
- app_file "lib/zoo/reptile_house.rb", <<-ZOO
- module Zoo::ReptileHouse ; end
- ZOO
-
- add_to_config <<-RUBY
- config.root = "#{app_path}"
- config.eager_load_paths = "#{app_path}/lib"
- RUBY
-
- require "#{app_path}/config/environment"
-
- assert Zoo
- end
-
- test "load environment with global" do
- app_file "config/environments/development.rb", "$initialize_test_set_from_env = 'success'"
- assert_nil $initialize_test_set_from_env
- add_to_config <<-RUBY
- config.root = "#{app_path}"
- RUBY
- require "#{app_path}/config/environment"
- assert_equal "success", $initialize_test_set_from_env
- end
-
- test "action_controller load paths set only if action controller in use" do
- assert_nothing_raised NameError do
- add_to_config <<-RUBY
- config.root = "#{app_path}"
- RUBY
-
- use_frameworks []
- require "#{app_path}/config/environment"
- end
- end
-
- test "after_initialize block works correctly" do
- add_to_config <<-RUBY
- config.root = "#{app_path}"
- config.after_initialize { $test_after_initialize_block1 = "success" }
- config.after_initialize { $test_after_initialize_block2 = "congratulations" }
- RUBY
- require "#{app_path}/config/environment"
-
- assert_equal "success", $test_after_initialize_block1
- assert_equal "congratulations", $test_after_initialize_block2
- end
-
- test "after_initialize block works correctly when no block is passed" do
- add_to_config <<-RUBY
- config.root = "#{app_path}"
- config.after_initialize { $test_after_initialize_block1 = "success" }
- config.after_initialize # don't pass a block, this is what we're testing!
- config.after_initialize { $test_after_initialize_block2 = "congratulations" }
- RUBY
- require "#{app_path}/config/environment"
-
- assert_equal "success", $test_after_initialize_block1
- assert_equal "congratulations", $test_after_initialize_block2
- end
-
- test "after_initialize runs after frameworks have been initialized" do
- $activerecord_configurations = nil
- add_to_config <<-RUBY
- config.after_initialize { $activerecord_configurations = ActiveRecord::Base.configurations }
- RUBY
-
- require "#{app_path}/config/environment"
- assert $activerecord_configurations
- assert $activerecord_configurations['development']
- end
-
- # i18n
- test "setting another default locale" do
- add_to_config <<-RUBY
- config.root = "#{app_path}"
- config.i18n.default_locale = :de
- RUBY
- require "#{app_path}/config/environment"
-
- assert_equal :de, I18n.default_locale
- end
-
- test "no config locales dir present should return empty load path" do
- FileUtils.rm_rf "#{app_path}/config/locales"
- add_to_config <<-RUBY
- config.root = "#{app_path}"
- RUBY
- require "#{app_path}/config/environment"
-
- assert_equal [], Rails.application.config.i18n.load_path
- end
-
- test "config locales dir present should be added to load path" do
- add_to_config <<-RUBY
- config.root = "#{app_path}"
- RUBY
-
- require "#{app_path}/config/environment"
- assert_equal ["#{app_path}/config/locales/en.yml"], Rails.application.config.i18n.load_path
- end
-
- test "config defaults should be added with config settings" do
- add_to_config <<-RUBY
- config.root = "#{app_path}"
- config.i18n.load_path << "my/other/locale.yml"
- RUBY
- require "#{app_path}/config/environment"
-
- assert_equal [
- "#{app_path}/config/locales/en.yml", "my/other/locale.yml"
- ], Rails.application.config.i18n.load_path
- end
-
- # DB middleware
- test "database middleware doesn't initialize when session store is not active_record" do
- add_to_config <<-RUBY
- config.root = "#{app_path}"
- config.action_controller.session_store = :cookie_store
- RUBY
- require "#{app_path}/config/environment"
-
- assert !Rails.application.config.middleware.include?(ActiveRecord::SessionStore)
- end
-
- test "database middleware initializes when session store is active record" do
- add_to_config "config.action_controller.session_store = :active_record_store"
-
- require "#{app_path}/config/environment"
-
- expects = [ActiveRecord::ConnectionAdapters::ConnectionManagement, ActiveRecord::QueryCache, ActiveRecord::SessionStore]
- middleware = Rails.application.config.middleware.map { |m| m.klass }
- assert_equal expects, middleware & expects
- end
-
- test "Rails.root should be a Pathname" do
- add_to_config <<-RUBY
- config.root = "#{app_path}"
- RUBY
- require "#{app_path}/config/environment"
- assert_instance_of Pathname, Rails.root
- end
- end
-
- class InitializerCustomFrameworkExtensionsTest < Test::Unit::TestCase
- include ActiveSupport::Testing::Isolation
-
- def setup
- build_app
- boot_rails
- FileUtils.rm_rf "#{app_path}/config/environments"
- end
-
- test "database middleware doesn't initialize when activerecord is not in frameworks" do
- use_frameworks []
- require "#{app_path}/config/environment"
-
- assert_nil defined?(ActiveRecord)
- end
- end
-end
diff --git a/railties/test/initializer/boot_test.rb b/railties/test/application/initializers/boot_test.rb
index 5ee3c45b21..5ec562f12f 100644
--- a/railties/test/initializer/boot_test.rb
+++ b/railties/test/application/initializers/boot_test.rb
@@ -1,6 +1,6 @@
require "isolation/abstract_unit"
-module BootTests
+module ApplicationTests
class GemBooting < Test::Unit::TestCase
include ActiveSupport::Testing::Isolation
diff --git a/railties/test/initializer/check_ruby_version_test.rb b/railties/test/application/initializers/check_ruby_version_test.rb
index 311f19a28a..58782b2511 100644
--- a/railties/test/initializer/check_ruby_version_test.rb
+++ b/railties/test/application/initializers/check_ruby_version_test.rb
@@ -1,6 +1,6 @@
require "isolation/abstract_unit"
-module InitializerTests
+module ApplicationTests
class CheckRubyVersionTest < Test::Unit::TestCase
include ActiveSupport::Testing::Isolation
diff --git a/railties/test/application/initializers/frameworks_test.rb b/railties/test/application/initializers/frameworks_test.rb
new file mode 100644
index 0000000000..1e7b9c9997
--- /dev/null
+++ b/railties/test/application/initializers/frameworks_test.rb
@@ -0,0 +1,86 @@
+require "isolation/abstract_unit"
+
+module ApplicationTests
+ class FrameworlsTest < Test::Unit::TestCase
+ include ActiveSupport::Testing::Isolation
+
+ def setup
+ build_app
+ boot_rails
+ FileUtils.rm_rf "#{app_path}/config/environments"
+ end
+
+ # AC & AM
+ test "set load paths set only if action controller or action mailer are in use" do
+ assert_nothing_raised NameError do
+ add_to_config <<-RUBY
+ config.root = "#{app_path}"
+ RUBY
+
+ use_frameworks []
+ require "#{app_path}/config/environment"
+ end
+ end
+
+ test "sets action_controller and action_mailer load paths" do
+ add_to_config <<-RUBY
+ config.root = "#{app_path}"
+ RUBY
+
+ require "#{app_path}/config/environment"
+ ActionController::Base.view_paths.include?(File.expand_path("app/views", app_path))
+ ActionMailer::Base.view_paths.include?(File.expand_path("app/views", app_path))
+ end
+
+ # AS
+ test "if there's no config.active_support.bare, all of ActiveSupport is required" do
+ use_frameworks []
+ require "#{app_path}/config/environment"
+ assert_nothing_raised { [1,2,3].rand }
+ end
+
+ test "config.active_support.bare does not require all of ActiveSupport" do
+ add_to_config "config.active_support.bare = true"
+
+ use_frameworks []
+
+ Dir.chdir("#{app_path}/app") do
+ require "#{app_path}/config/environment"
+ assert_raises(NoMethodError) { [1,2,3].rand }
+ end
+ end
+
+ # AR
+ test "database middleware doesn't initialize when session store is not active_record" do
+ add_to_config <<-RUBY
+ config.root = "#{app_path}"
+ config.action_controller.session_store = :cookie_store
+ RUBY
+ require "#{app_path}/config/environment"
+
+ assert !Rails.application.config.middleware.include?(ActiveRecord::SessionStore)
+ end
+
+ test "database middleware initializes when session store is active record" do
+ add_to_config "config.action_controller.session_store = :active_record_store"
+
+ require "#{app_path}/config/environment"
+
+ expects = [ActiveRecord::ConnectionAdapters::ConnectionManagement, ActiveRecord::QueryCache, ActiveRecord::SessionStore]
+ middleware = Rails.application.config.middleware.map { |m| m.klass }
+ assert_equal expects, middleware & expects
+ end
+
+ test "active_record extensions are applied to ActiveRecord" do
+ add_to_config "config.active_record.table_name_prefix = 'tbl_'"
+ require "#{app_path}/config/environment"
+ assert_equal 'tbl_', ActiveRecord::Base.table_name_prefix
+ end
+
+ test "database middleware doesn't initialize when activerecord is not in frameworks" do
+ use_frameworks []
+ require "#{app_path}/config/environment"
+ assert_nil defined?(ActiveRecord)
+ end
+ end
+end
diff --git a/railties/test/application/initializers/i18n_test.rb b/railties/test/application/initializers/i18n_test.rb
new file mode 100644
index 0000000000..99b2d86013
--- /dev/null
+++ b/railties/test/application/initializers/i18n_test.rb
@@ -0,0 +1,55 @@
+require "isolation/abstract_unit"
+
+module ApplicationTests
+ class I18nTest < Test::Unit::TestCase
+ include ActiveSupport::Testing::Isolation
+
+ def setup
+ build_app
+ boot_rails
+ FileUtils.rm_rf "#{app_path}/config/environments"
+ end
+
+ # i18n
+ test "setting another default locale" do
+ add_to_config <<-RUBY
+ config.root = "#{app_path}"
+ config.i18n.default_locale = :de
+ RUBY
+ require "#{app_path}/config/environment"
+
+ assert_equal :de, I18n.default_locale
+ end
+
+ test "no config locales dir present should return empty load path" do
+ FileUtils.rm_rf "#{app_path}/config/locales"
+ add_to_config <<-RUBY
+ config.root = "#{app_path}"
+ RUBY
+ require "#{app_path}/config/environment"
+
+ assert_equal [], Rails.application.config.i18n.load_path
+ end
+
+ test "config locales dir present should be added to load path" do
+ add_to_config <<-RUBY
+ config.root = "#{app_path}"
+ RUBY
+
+ require "#{app_path}/config/environment"
+ assert_equal ["#{app_path}/config/locales/en.yml"], Rails.application.config.i18n.load_path
+ end
+
+ test "config defaults should be added with config settings" do
+ add_to_config <<-RUBY
+ config.root = "#{app_path}"
+ config.i18n.load_path << "my/other/locale.yml"
+ RUBY
+ require "#{app_path}/config/environment"
+
+ assert_equal [
+ "#{app_path}/config/locales/en.yml", "my/other/locale.yml"
+ ], Rails.application.config.i18n.load_path
+ end
+ end
+end \ No newline at end of file
diff --git a/railties/test/application/initializers/initializers_test.rb b/railties/test/application/initializers/initializers_test.rb
new file mode 100644
index 0000000000..0c3de7ce33
--- /dev/null
+++ b/railties/test/application/initializers/initializers_test.rb
@@ -0,0 +1,55 @@
+require "isolation/abstract_unit"
+
+module ApplicationTests
+ class InitializersTest < Test::Unit::TestCase
+ include ActiveSupport::Testing::Isolation
+
+ def setup
+ build_app
+ boot_rails
+ FileUtils.rm_rf "#{app_path}/config/environments"
+ end
+
+ test "load initializers" do
+ app_file "config/initializers/foo.rb", "$foo = true"
+ require "#{app_path}/config/environment"
+ assert $foo
+ end
+
+ test "after_initialize block works correctly" do
+ add_to_config <<-RUBY
+ config.root = "#{app_path}"
+ config.after_initialize { $test_after_initialize_block1 = "success" }
+ config.after_initialize { $test_after_initialize_block2 = "congratulations" }
+ RUBY
+ require "#{app_path}/config/environment"
+
+ assert_equal "success", $test_after_initialize_block1
+ assert_equal "congratulations", $test_after_initialize_block2
+ end
+
+ test "after_initialize block works correctly when no block is passed" do
+ add_to_config <<-RUBY
+ config.root = "#{app_path}"
+ config.after_initialize { $test_after_initialize_block1 = "success" }
+ config.after_initialize # don't pass a block, this is what we're testing!
+ config.after_initialize { $test_after_initialize_block2 = "congratulations" }
+ RUBY
+ require "#{app_path}/config/environment"
+
+ assert_equal "success", $test_after_initialize_block1
+ assert_equal "congratulations", $test_after_initialize_block2
+ end
+
+ test "after_initialize runs after frameworks have been initialized" do
+ $activerecord_configurations = nil
+ add_to_config <<-RUBY
+ config.after_initialize { $activerecord_configurations = ActiveRecord::Base.configurations }
+ RUBY
+
+ require "#{app_path}/config/environment"
+ assert $activerecord_configurations
+ assert $activerecord_configurations['development']
+ end
+ end
+end
diff --git a/railties/test/application/initializers/load_path_test.rb b/railties/test/application/initializers/load_path_test.rb
new file mode 100644
index 0000000000..b39b9ecaae
--- /dev/null
+++ b/railties/test/application/initializers/load_path_test.rb
@@ -0,0 +1,74 @@
+require "isolation/abstract_unit"
+
+module ApplicationTests
+ class LoadPathTest < Test::Unit::TestCase
+ include ActiveSupport::Testing::Isolation
+
+ def setup
+ build_app
+ boot_rails
+ FileUtils.rm_rf "#{app_path}/config/environments"
+ end
+
+ test "initializing an application adds the application paths to the load path" do
+ add_to_config <<-RUBY
+ config.root = "#{app_path}"
+ RUBY
+
+ require "#{app_path}/config/environment"
+ assert $:.include?("#{app_path}/app/models")
+ end
+
+ test "initializing an application eager load any path under app" do
+ app_file "app/anything/foo.rb", <<-RUBY
+ module Foo; end
+ RUBY
+
+ add_to_config <<-RUBY
+ config.root = "#{app_path}"
+ RUBY
+
+ require "#{app_path}/config/environment"
+ assert Foo
+ end
+
+ test "eager loading loads parent classes before children" do
+ app_file "lib/zoo.rb", <<-ZOO
+ class Zoo ; include ReptileHouse ; end
+ ZOO
+
+ app_file "lib/zoo/reptile_house.rb", <<-ZOO
+ module Zoo::ReptileHouse ; end
+ ZOO
+
+ add_to_config <<-RUBY
+ config.root = "#{app_path}"
+ config.eager_load_paths << "#{app_path}/lib"
+ RUBY
+
+ require "#{app_path}/config/environment"
+ assert Zoo
+ end
+
+ test "load environment with global" do
+ app_file "config/environments/development.rb", <<-RUBY
+ $initialize_test_set_from_env = 'success'
+ AppTemplate::Application.configure do
+ config.cache_classes = true
+ config.time_zone = "Brasilia"
+ end
+ RUBY
+
+ assert_nil $initialize_test_set_from_env
+ add_to_config <<-RUBY
+ config.root = "#{app_path}"
+ config.time_zone = "UTC"
+ RUBY
+
+ require "#{app_path}/config/environment"
+ assert_equal "success", $initialize_test_set_from_env
+ assert AppTemplate::Application.config.cache_classes
+ assert_equal "Brasilia", AppTemplate::Application.config.time_zone
+ end
+ end
+end
diff --git a/railties/test/application/notifications_test.rb b/railties/test/application/initializers/notifications_test.rb
index db8605edbe..061bb34c19 100644
--- a/railties/test/application/notifications_test.rb
+++ b/railties/test/application/initializers/notifications_test.rb
@@ -1,17 +1,6 @@
require "isolation/abstract_unit"
module ApplicationTests
- class MyQueue
- def publish(name, *args)
- raise name
- end
-
- # Not a full queue implementation
- def method_missing(name, *args, &blk)
- self
- end
- end
-
class MockLogger
def method_missing(*args)
@logged ||= []
@@ -39,22 +28,6 @@ module ApplicationTests
ActiveSupport::Notifications.notifier.wait
end
- test "new queue is set" do
- # We don't want to load all frameworks, so remove them and clean up environments.
- use_frameworks []
- FileUtils.rm_rf("#{app_path}/config/environments")
-
- add_to_config <<-RUBY
- config.notifications.notifier = ActiveSupport::Notifications::Notifier.new(ApplicationTests::MyQueue.new)
- RUBY
-
- require "#{app_path}/config/environment"
-
- assert_raise RuntimeError do
- ActiveSupport::Notifications.publish('foo')
- end
- end
-
test "rails subscribers are added" do
add_to_config <<-RUBY
config.colorize_logging = false
diff --git a/railties/test/application/middleware_test.rb b/railties/test/application/middleware_test.rb
index 31696598ce..0b92cdba54 100644
--- a/railties/test/application/middleware_test.rb
+++ b/railties/test/application/middleware_test.rb
@@ -23,7 +23,6 @@ module ApplicationTests
"ActionDispatch::Cookies",
"ActionDispatch::Session::CookieStore",
"ActionDispatch::Flash",
- "ActionDispatch::Cascade",
"ActionDispatch::ParamsParser",
"Rack::MethodOverride",
"ActionDispatch::Head",
@@ -70,6 +69,12 @@ module ApplicationTests
assert_equal "Rack::Config", middleware.first
end
+ test "shows cascade if any metal exists" do
+ app_file "app/metal/foo.rb", "class Foo; end"
+ boot!
+ assert middleware.include?("ActionDispatch::Cascade")
+ end
+
private
def boot!
require "#{app_path}/config/environment"
diff --git a/railties/test/initializer/path_test.rb b/railties/test/application/paths_test.rb
index 328dda6d2c..ac0aa27c64 100644
--- a/railties/test/initializer/path_test.rb
+++ b/railties/test/application/paths_test.rb
@@ -1,13 +1,14 @@
require "isolation/abstract_unit"
-module InitializerTests
- class PathTest < Test::Unit::TestCase
+module ApplicationTests
+ class PathsTest < Test::Unit::TestCase
include ActiveSupport::Testing::Isolation
def setup
build_app
boot_rails
FileUtils.rm_rf("#{app_path}/config/environments")
+ app_file "config/environments/development.rb", ""
add_to_config <<-RUBY
config.root = "#{app_path}"
config.after_initialize do
@@ -36,19 +37,18 @@ module InitializerTests
end
test "booting up Rails yields a valid paths object" do
- assert_path @paths.app, "app"
- assert_path @paths.app.metals, "app", "metal"
assert_path @paths.app.models, "app", "models"
+ assert_path @paths.app.metals, "app", "metal"
assert_path @paths.app.helpers, "app", "helpers"
- assert_path @paths.app.services, "app", "services"
+ assert_path @paths.app.views, "app", "views"
assert_path @paths.lib, "lib"
assert_path @paths.vendor, "vendor"
assert_path @paths.vendor.plugins, "vendor", "plugins"
assert_path @paths.tmp, "tmp"
assert_path @paths.tmp.cache, "tmp", "cache"
assert_path @paths.config, "config"
- assert_path @paths.config.locales, "config", "locales"
- assert_path @paths.config.environments, "config", "environments"
+ assert_path @paths.config.locales, "config", "locales", "en.yml"
+ assert_path @paths.config.environment, "config", "environments", "development.rb"
assert_equal root("app", "controllers"), @paths.app.controllers.to_a.first
assert_equal Pathname.new(File.dirname(__FILE__)).join("..", "..", "builtin", "rails_info").expand_path,
@@ -56,27 +56,23 @@ module InitializerTests
end
test "booting up Rails yields a list of paths that are eager" do
- assert @paths.app.models.eager_load?
+ assert @paths.app.eager_load?
assert @paths.app.controllers.eager_load?
assert @paths.app.helpers.eager_load?
- assert @paths.app.metals.eager_load?
end
test "environments has a glob equal to the current environment" do
- assert_equal "#{Rails.env}.rb", @paths.config.environments.glob
+ assert_equal "#{Rails.env}.rb", @paths.config.environment.glob
end
test "load path includes each of the paths in config.paths as long as the directories exist" do
- assert_in_load_path "app"
assert_in_load_path "app", "controllers"
assert_in_load_path "app", "models"
assert_in_load_path "app", "helpers"
assert_in_load_path "lib"
assert_in_load_path "vendor"
- assert_not_in_load_path "app", "views"
assert_not_in_load_path "app", "metal"
- assert_not_in_load_path "app", "services"
assert_not_in_load_path "config"
assert_not_in_load_path "config", "locales"
assert_not_in_load_path "config", "environments"
@@ -86,17 +82,17 @@ module InitializerTests
test "controller paths include builtin in development mode" do
Rails.env.replace "development"
- assert Rails::Configuration.new.paths.app.controllers.paths.any? { |p| p =~ /builtin/ }
+ assert Rails::Application::Configuration.new("/").paths.app.controllers.paths.any? { |p| p =~ /builtin/ }
end
test "controller paths does not have builtin_directories in test mode" do
Rails.env.replace "test"
- assert !Rails::Configuration.new.paths.app.controllers.paths.any? { |p| p =~ /builtin/ }
+ assert !Rails::Application::Configuration.new("/").paths.app.controllers.paths.any? { |p| p =~ /builtin/ }
end
test "controller paths does not have builtin_directories in production mode" do
Rails.env.replace "production"
- assert !Rails::Configuration.new.paths.app.controllers.paths.any? { |p| p =~ /builtin/ }
+ assert !Rails::Application::Configuration.new("/").paths.app.controllers.paths.any? { |p| p =~ /builtin/ }
end
end
diff --git a/railties/test/application/load_test.rb b/railties/test/application/rackup_test.rb
index 1c5811b07a..f909c1b282 100644
--- a/railties/test/application/load_test.rb
+++ b/railties/test/application/rackup_test.rb
@@ -1,7 +1,7 @@
require "isolation/abstract_unit"
module ApplicationTests
- class LoadTest < Test::Unit::TestCase
+ class RackupTest < Test::Unit::TestCase
include ActiveSupport::Testing::Isolation
def rackup
diff --git a/railties/test/application/routing_test.rb b/railties/test/application/routing_test.rb
index 50cb9e3acc..b93e349a46 100644
--- a/railties/test/application/routing_test.rb
+++ b/railties/test/application/routing_test.rb
@@ -14,7 +14,6 @@ module ApplicationTests
def app
@app ||= begin
require "#{app_path}/config/environment"
-
Rails.application
end
end
@@ -26,7 +25,7 @@ module ApplicationTests
test "simple controller" do
controller :foo, <<-RUBY
- class FooController < ActionController::Base
+ class FooController < ApplicationController
def index
render :text => "foo"
end
@@ -43,9 +42,36 @@ module ApplicationTests
assert_equal 'foo', last_response.body
end
+ test "simple controller with helper" do
+ controller :foo, <<-RUBY
+ class FooController < ApplicationController
+ def index
+ render :inline => "<%= foo_or_bar? %>"
+ end
+ end
+ RUBY
+
+ app_file 'app/helpers/bar_helper.rb', <<-RUBY
+ module BarHelper
+ def foo_or_bar?
+ "bar"
+ end
+ end
+ RUBY
+
+ app_file 'config/routes.rb', <<-RUBY
+ AppTemplate::Application.routes.draw do |map|
+ match ':controller(/:action)'
+ end
+ RUBY
+
+ get '/foo'
+ assert_equal 'bar', last_response.body
+ end
+
test "multiple controllers" do
controller :foo, <<-RUBY
- class FooController < ActionController::Base
+ class FooController < ApplicationController
def index
render :text => "foo"
end
@@ -75,7 +101,7 @@ module ApplicationTests
test "nested controller" do
controller 'foo', <<-RUBY
- class FooController < ActionController::Base
+ class FooController < ApplicationController
def index
render :text => "foo"
end
@@ -84,7 +110,7 @@ module ApplicationTests
controller 'admin/foo', <<-RUBY
module Admin
- class FooController < ActionController::Base
+ class FooController < ApplicationController
def index
render :text => "admin::foo"
end
@@ -105,47 +131,9 @@ module ApplicationTests
assert_equal 'admin::foo', last_response.body
end
- test "merges with plugin routes" do
- controller 'foo', <<-RUBY
- class FooController < ActionController::Base
- def index
- render :text => "foo"
- end
- end
- RUBY
-
- app_file 'config/routes.rb', <<-RUBY
- AppTemplate::Application.routes.draw do |map|
- match 'foo', :to => 'foo#index'
- end
- RUBY
-
- plugin 'bar', 'require File.dirname(__FILE__) + "/app/controllers/bar"' do |plugin|
- plugin.write 'app/controllers/bar.rb', <<-RUBY
- class BarController < ActionController::Base
- def index
- render :text => "bar"
- end
- end
- RUBY
-
- plugin.write 'config/routes.rb', <<-RUBY
- AppTemplate::Application.routes.draw do |map|
- match 'bar', :to => 'bar#index'
- end
- RUBY
- end
-
- get '/foo'
- assert_equal 'foo', last_response.body
-
- get '/bar'
- assert_equal 'bar', last_response.body
- end
-
test "reloads routes when configuration is changed" do
controller :foo, <<-RUBY
- class FooController < ActionController::Base
+ class FooController < ApplicationController
def bar
render :text => "bar"
end
@@ -191,7 +179,7 @@ module ApplicationTests
RUBY
controller 'yazilar', <<-RUBY
- class YazilarController < ActionController::Base
+ class YazilarController < ApplicationController
def index
render :text => 'yazilar#index'
end
diff --git a/railties/test/fixtures/eager/zoo.rb b/railties/test/fixtures/eager/zoo.rb
deleted file mode 100644
index 8b10ef984b..0000000000
--- a/railties/test/fixtures/eager/zoo.rb
+++ /dev/null
@@ -1,3 +0,0 @@
-class Zoo
- include ReptileHouse
-end \ No newline at end of file
diff --git a/railties/test/fixtures/eager/zoo/reptile_house.rb b/railties/test/fixtures/eager/zoo/reptile_house.rb
deleted file mode 100644
index 82bbafce79..0000000000
--- a/railties/test/fixtures/eager/zoo/reptile_house.rb
+++ /dev/null
@@ -1,2 +0,0 @@
-module Zoo::ReptileHouse
-end \ No newline at end of file
diff --git a/railties/test/fixtures/environment_with_constant.rb b/railties/test/fixtures/environment_with_constant.rb
deleted file mode 100644
index 23e1f7afd9..0000000000
--- a/railties/test/fixtures/environment_with_constant.rb
+++ /dev/null
@@ -1 +0,0 @@
-$initialize_test_set_from_env = 'success'
diff --git a/railties/test/fixtures/plugins/alternate/a/generators/a_generator/a_generator.rb b/railties/test/fixtures/plugins/alternate/a/generators/a_generator/a_generator.rb
deleted file mode 100644
index b33f2dad18..0000000000
--- a/railties/test/fixtures/plugins/alternate/a/generators/a_generator/a_generator.rb
+++ /dev/null
@@ -1,4 +0,0 @@
-class AGenerator < Rails::Generator::Base
- def manifest
- end
-end
diff --git a/railties/test/fixtures/plugins/alternate/a/lib/.gitignore b/railties/test/fixtures/plugins/alternate/a/lib/.gitignore
deleted file mode 100644
index e69de29bb2..0000000000
--- a/railties/test/fixtures/plugins/alternate/a/lib/.gitignore
+++ /dev/null
diff --git a/railties/test/fixtures/plugins/default/acts/acts_as_chunky_bacon/lib/.gitignore b/railties/test/fixtures/plugins/default/acts/acts_as_chunky_bacon/lib/.gitignore
deleted file mode 100644
index e69de29bb2..0000000000
--- a/railties/test/fixtures/plugins/default/acts/acts_as_chunky_bacon/lib/.gitignore
+++ /dev/null
diff --git a/railties/test/fixtures/plugins/default/empty/.gitignore b/railties/test/fixtures/plugins/default/empty/.gitignore
deleted file mode 100644
index e69de29bb2..0000000000
--- a/railties/test/fixtures/plugins/default/empty/.gitignore
+++ /dev/null
diff --git a/railties/test/fixtures/plugins/default/gemlike/init.rb b/railties/test/fixtures/plugins/default/gemlike/init.rb
deleted file mode 100644
index 6a771b5b68..0000000000
--- a/railties/test/fixtures/plugins/default/gemlike/init.rb
+++ /dev/null
@@ -1 +0,0 @@
-raise 'This init.rb should not be evaluated because rails/init.rb exists'
diff --git a/railties/test/fixtures/plugins/default/gemlike/lib/gemlike.rb b/railties/test/fixtures/plugins/default/gemlike/lib/gemlike.rb
deleted file mode 100644
index 2088103e45..0000000000
--- a/railties/test/fixtures/plugins/default/gemlike/lib/gemlike.rb
+++ /dev/null
@@ -1,2 +0,0 @@
-module Gemlike
-end \ No newline at end of file
diff --git a/railties/test/fixtures/plugins/default/gemlike/rails/init.rb b/railties/test/fixtures/plugins/default/gemlike/rails/init.rb
deleted file mode 100644
index 171a293eb3..0000000000
--- a/railties/test/fixtures/plugins/default/gemlike/rails/init.rb
+++ /dev/null
@@ -1,7 +0,0 @@
-# I have access to my directory and the Rails config.
-raise 'directory expected but undefined in init.rb' unless defined? directory
-raise 'config expected but undefined in init.rb' unless defined? config
-
-# My lib/ dir must be in the load path.
-require 'gemlike'
-raise 'missing mixin from my lib/ dir' unless defined? Gemlike
diff --git a/railties/test/fixtures/plugins/default/plugin_with_no_lib_dir/init.rb b/railties/test/fixtures/plugins/default/plugin_with_no_lib_dir/init.rb
deleted file mode 100644
index e69de29bb2..0000000000
--- a/railties/test/fixtures/plugins/default/plugin_with_no_lib_dir/init.rb
+++ /dev/null
diff --git a/railties/test/fixtures/plugins/default/stubby/about.yml b/railties/test/fixtures/plugins/default/stubby/about.yml
deleted file mode 100644
index d85a7cc0e3..0000000000
--- a/railties/test/fixtures/plugins/default/stubby/about.yml
+++ /dev/null
@@ -1,2 +0,0 @@
-author: Plugin Author
-version: 1.0.0 \ No newline at end of file
diff --git a/railties/test/fixtures/plugins/default/stubby/init.rb b/railties/test/fixtures/plugins/default/stubby/init.rb
deleted file mode 100644
index 81beeb0d32..0000000000
--- a/railties/test/fixtures/plugins/default/stubby/init.rb
+++ /dev/null
@@ -1,7 +0,0 @@
-# I have access to my directory and the Rails config.
-raise 'directory expected but undefined in init.rb' unless defined? directory
-raise 'config expected but undefined in init.rb' unless defined? config
-
-# My lib/ dir must be in the load path.
-require 'stubby_mixin'
-raise 'missing mixin from my lib/ dir' unless defined? StubbyMixin
diff --git a/railties/test/fixtures/plugins/default/stubby/lib/stubby_mixin.rb b/railties/test/fixtures/plugins/default/stubby/lib/stubby_mixin.rb
deleted file mode 100644
index 2d569e5002..0000000000
--- a/railties/test/fixtures/plugins/default/stubby/lib/stubby_mixin.rb
+++ /dev/null
@@ -1,2 +0,0 @@
-module StubbyMixin
-end
diff --git a/railties/test/fixtures/plugins/engines/engine/app/controllers/engine_controller.rb b/railties/test/fixtures/plugins/engines/engine/app/controllers/engine_controller.rb
deleted file mode 100644
index 323ee1c4dc..0000000000
--- a/railties/test/fixtures/plugins/engines/engine/app/controllers/engine_controller.rb
+++ /dev/null
@@ -1,2 +0,0 @@
-class EngineController
-end \ No newline at end of file
diff --git a/railties/test/fixtures/plugins/engines/engine/app/metal/engine_metal.rb b/railties/test/fixtures/plugins/engines/engine/app/metal/engine_metal.rb
deleted file mode 100644
index d67a127ca7..0000000000
--- a/railties/test/fixtures/plugins/engines/engine/app/metal/engine_metal.rb
+++ /dev/null
@@ -1,10 +0,0 @@
-class EngineMetal
- def self.call(env)
- if env["PATH_INFO"] =~ /^\/metal/
- [200, {"Content-Type" => "text/html"}, ["Engine metal"]]
- else
- [404, {"Content-Type" => "text/html"}, ["Not Found"]]
- end
- end
-end
-
diff --git a/railties/test/fixtures/plugins/engines/engine/app/models/engine_model.rb b/railties/test/fixtures/plugins/engines/engine/app/models/engine_model.rb
deleted file mode 100644
index e265712185..0000000000
--- a/railties/test/fixtures/plugins/engines/engine/app/models/engine_model.rb
+++ /dev/null
@@ -1,2 +0,0 @@
-class EngineModel
-end \ No newline at end of file
diff --git a/railties/test/fixtures/plugins/engines/engine/config/locales/en.yml b/railties/test/fixtures/plugins/engines/engine/config/locales/en.yml
deleted file mode 100644
index 641a7e035c..0000000000
--- a/railties/test/fixtures/plugins/engines/engine/config/locales/en.yml
+++ /dev/null
@@ -1,2 +0,0 @@
-en:
- hello: "Hello from Engine"
diff --git a/railties/test/fixtures/plugins/engines/engine/config/routes.rb b/railties/test/fixtures/plugins/engines/engine/config/routes.rb
deleted file mode 100644
index da44595693..0000000000
--- a/railties/test/fixtures/plugins/engines/engine/config/routes.rb
+++ /dev/null
@@ -1,3 +0,0 @@
-ActionController::Routing::Routes.draw do |map|
- match '/engine', :to => "engine"
-end
diff --git a/railties/test/fixtures/plugins/engines/engine/init.rb b/railties/test/fixtures/plugins/engines/engine/init.rb
deleted file mode 100644
index 64e9ae6c30..0000000000
--- a/railties/test/fixtures/plugins/engines/engine/init.rb
+++ /dev/null
@@ -1,3 +0,0 @@
-# My app/models dir must be in the load path.
-require 'engine_model'
-raise LoadError, 'missing model from my app/models dir' unless defined?(EngineModel)
diff --git a/railties/test/generators/generators_test_helper.rb b/railties/test/generators/generators_test_helper.rb
index 3cd16a69f9..d17be5b964 100644
--- a/railties/test/generators/generators_test_helper.rb
+++ b/railties/test/generators/generators_test_helper.rb
@@ -9,7 +9,7 @@ Rails.application.config.root = Rails.root
require 'rails/generators'
require 'rails/generators/test_case'
-
+Rails::Generators.configure!
require 'active_record'
require 'action_dispatch'
diff --git a/railties/test/generators/mailer_generator_test.rb b/railties/test/generators/mailer_generator_test.rb
index dfc3130f77..e6fc1bbb5c 100644
--- a/railties/test/generators/mailer_generator_test.rb
+++ b/railties/test/generators/mailer_generator_test.rb
@@ -7,7 +7,18 @@ class MailerGeneratorTest < Rails::Generators::TestCase
def test_mailer_skeleton_is_created
run_generator
- assert_file "app/mailers/notifier.rb", /class Notifier < ActionMailer::Base/
+ assert_file "app/mailers/notifier.rb" do |mailer|
+ assert_match /class Notifier < ActionMailer::Base/, mailer
+ assert_match /default :from => "from@example.com"/, mailer
+ end
+ end
+
+ def test_mailer_with_i18n_helper
+ run_generator
+ assert_file "app/mailers/notifier.rb" do |mailer|
+ assert_match /en\.actionmailer\.notifier\.foo\.subject/, mailer
+ assert_match /en\.actionmailer\.notifier\.bar\.subject/, mailer
+ end
end
def test_check_class_collision
@@ -24,8 +35,15 @@ class MailerGeneratorTest < Rails::Generators::TestCase
def test_invokes_default_template_engine
run_generator
- assert_file "app/views/notifier/foo.erb", /app\/views\/notifier\/foo/
- assert_file "app/views/notifier/bar.erb", /app\/views\/notifier\/bar/
+ assert_file "app/views/notifier/foo.text.erb" do |view|
+ assert_match /app\/views\/notifier\/foo/, view
+ assert_match /<%= @greeting %>/, view
+ end
+
+ assert_file "app/views/notifier/bar.text.erb" do |view|
+ assert_match /app\/views\/notifier\/bar/, view
+ assert_match /<%= @greeting %>/, view
+ end
end
def test_invokes_default_template_engine_even_with_no_action
@@ -40,7 +58,18 @@ class MailerGeneratorTest < Rails::Generators::TestCase
def test_actions_are_turned_into_methods
run_generator
- assert_file "app/mailers/notifier.rb", /def foo/
- assert_file "app/mailers/notifier.rb", /def bar/
+
+ assert_file "app/mailers/notifier.rb" do |mailer|
+ assert_instance_method :foo, mailer do |foo|
+ assert_match /mail :to => "to@example.org"/, foo
+ assert_match /@greeting = "Hi"/, foo
+ end
+
+ assert_instance_method :bar, mailer do |bar|
+ assert_match /mail :to => "to@example.org"/, bar
+ assert_match /@greeting = "Hi"/, bar
+ end
+ end
+
end
end
diff --git a/railties/test/generators/named_base_test.rb b/railties/test/generators/named_base_test.rb
index 99eb431a49..f327fb1282 100644
--- a/railties/test/generators/named_base_test.rb
+++ b/railties/test/generators/named_base_test.rb
@@ -16,28 +16,68 @@ class NamedBaseTest < Rails::Generators::TestCase
tests Rails::Generators::ScaffoldControllerGenerator
def test_named_generator_attributes
- g = generator ["admin/foo"]
- assert_equal 'admin/foo', g.name
- assert_equal %w(admin), g.class_path
- assert_equal 1, g.class_nesting_depth
- assert_equal 'Admin::Foo', g.class_name
- assert_equal 'foo', g.singular_name
- assert_equal 'foos', g.plural_name
- assert_equal g.singular_name, g.file_name
- assert_equal "admin_#{g.plural_name}", g.table_name
+ g = generator ['admin/foo']
+ assert_name g, 'admin/foo', :name
+ assert_name g, %w(admin), :class_path
+ assert_name g, 'Admin::Foo', :class_name
+ assert_name g, 'admin/foo', :file_path
+ assert_name g, 'foo', :file_name
+ assert_name g, 'foo', :singular_name
+ assert_name g, 'foos', :plural_name
+ assert_name g, 'admin.foo', :i18n_scope
+ assert_name g, 'admin_foos', :table_name
+ end
+
+ def test_named_generator_attributes_as_ruby
+ g = generator ['Admin::Foo']
+ assert_name g, 'Admin::Foo', :name
+ assert_name g, %w(admin), :class_path
+ assert_name g, 'Admin::Foo', :class_name
+ assert_name g, 'admin/foo', :file_path
+ assert_name g, 'foo', :file_name
+ assert_name g, 'foo', :singular_name
+ assert_name g, 'foos', :plural_name
+ assert_name g, 'admin.foo', :i18n_scope
+ assert_name g, 'admin_foos', :table_name
end
def test_named_generator_attributes_without_pluralized
ActiveRecord::Base.pluralize_table_names = false
- g = generator ["admin/foo"]
- assert_equal "admin_#{g.singular_name}", g.table_name
+ g = generator ['admin/foo']
+ assert_name g, 'admin_foo', :table_name
end
def test_scaffold_plural_names
- g = generator ["ProductLine"]
- assert_equal "ProductLines", g.controller_name
- assert_equal "ProductLines", g.controller_class_name
- assert_equal "product_lines", g.controller_file_name
+ g = generator ['admin/foo']
+ assert_name g, 'admin/foos', :controller_name
+ assert_name g, %w(admin), :controller_class_path
+ assert_name g, 'Admin::Foos', :controller_class_name
+ assert_name g, 'admin/foos', :controller_file_path
+ assert_name g, 'foos', :controller_file_name
+ assert_name g, 'admin.foos', :controller_i18n_scope
+ end
+
+ def test_scaffold_plural_names_as_ruby
+ g = generator ['Admin::Foo']
+ assert_name g, 'Admin::Foos', :controller_name
+ assert_name g, %w(admin), :controller_class_path
+ assert_name g, 'Admin::Foos', :controller_class_name
+ assert_name g, 'admin/foos', :controller_file_path
+ assert_name g, 'foos', :controller_file_name
+ assert_name g, 'admin.foos', :controller_i18n_scope
end
+ def test_application_name
+ g = generator ['Admin::Foo']
+ Rails.stubs(:application).returns(Object.new)
+ assert_name g, "object", :application_name
+ Rails.stubs(:application).returns(nil)
+ assert_name g, "application", :application_name
+ end
+
+ protected
+
+ def assert_name(generator, value, method)
+ assert_equal value, generator.send(method)
+ end
end
diff --git a/railties/test/generators/plugin_generator_test.rb b/railties/test/generators/plugin_generator_test.rb
index 0a79e2cfb8..065dbe1423 100644
--- a/railties/test/generators/plugin_generator_test.rb
+++ b/railties/test/generators/plugin_generator_test.rb
@@ -48,7 +48,7 @@ class PluginGeneratorTest < Rails::Generators::TestCase
def test_creates_tasks_if_required
run_generator ["plugin_fu", "--tasks"]
- assert_file "vendor/plugins/plugin_fu/tasks/plugin_fu_tasks.rake"
+ assert_file "vendor/plugins/plugin_fu/lib/tasks/plugin_fu_tasks.rake"
end
def test_creates_generator_if_required
diff --git a/railties/test/generators_test.rb b/railties/test/generators_test.rb
index f37b684f73..33cc27bd84 100644
--- a/railties/test/generators_test.rb
+++ b/railties/test/generators_test.rb
@@ -99,6 +99,7 @@ class GeneratorsTest < Rails::Generators::TestCase
assert_match /Rails:/, output
assert_match /^ model$/, output
assert_match /^ scaffold_controller$/, output
+ assert_no_match /^ app$/, output
end
def test_rails_generators_with_others_information
diff --git a/railties/test/initializable_test.rb b/railties/test/initializable_test.rb
index e308cbcb0e..0c7378cb64 100644
--- a/railties/test/initializable_test.rb
+++ b/railties/test/initializable_test.rb
@@ -10,14 +10,14 @@ module InitializableTests
attr_accessor :foo, :bar
end
- initializer :omg, :global => true do
+ initializer :omg do
@foo ||= 0
@foo += 1
end
end
class Bar < Foo
- initializer :bar, :global => true do
+ initializer :bar do
@bar ||= 0
@bar += 1
end
@@ -26,7 +26,7 @@ module InitializableTests
module Word
include Rails::Initializable
- initializer :word, :global => true do
+ initializer :word do
$word = "bird"
end
end
@@ -34,11 +34,11 @@ module InitializableTests
class Parent
include Rails::Initializable
- initializer :one, :global => true do
+ initializer :one do
$arr << 1
end
- initializer :two, :global => true do
+ initializer :two do
$arr << 2
end
end
@@ -46,17 +46,17 @@ module InitializableTests
class Child < Parent
include Rails::Initializable
- initializer :three, :before => :one, :global => true do
+ initializer :three, :before => :one do
$arr << 3
end
- initializer :four, :after => :one, :global => true do
+ initializer :four, :after => :one do
$arr << 4
end
end
class Parent
- initializer :five, :before => :one, :global => true do
+ initializer :five, :before => :one do
$arr << 5
end
end
@@ -72,11 +72,11 @@ module InitializableTests
$arr << 2
end
- initializer :three, :global => true do
+ initializer :three do
$arr << 3
end
- initializer :four, :global => true do
+ initializer :four do
$arr << 4
end
end
@@ -181,13 +181,7 @@ module InitializableTests
$arr = []
instance = Instance.new
instance.run_initializers
- assert_equal [1, 2], $arr
- end
-
- test "running globals" do
- $arr = []
- Instance.run_initializers
- assert_equal [3, 4], $arr
+ assert_equal [1, 2, 3, 4], $arr
end
end
diff --git a/railties/test/initializer/initialize_i18n_test.rb b/railties/test/initializer/initialize_i18n_test.rb
deleted file mode 100644
index 472566378d..0000000000
--- a/railties/test/initializer/initialize_i18n_test.rb
+++ /dev/null
@@ -1,55 +0,0 @@
-require "isolation/abstract_unit"
-
-module InitializerTests
- class InitializeI18nTest < Test::Unit::TestCase
- include ActiveSupport::Testing::Isolation
-
- def setup
- build_app
- boot_rails
- end
-
- # test_config_defaults_and_settings_should_be_added_to_i18n_defaults
- test "i18n config defaults and settings should be added to i18n defaults" do
- add_to_config <<-RUBY
- config.root = "#{app_path}"
- config.i18n.load_path << "my/other/locale.yml"
- RUBY
- require "#{app_path}/config/environment"
-
- #{RAILS_FRAMEWORK_ROOT}/railties/test/fixtures/plugins/engines/engine/config/locales/en.yml
- assert_equal %W(
- #{RAILS_FRAMEWORK_ROOT}/activesupport/lib/active_support/locale/en.yml
- #{RAILS_FRAMEWORK_ROOT}/activemodel/lib/active_model/locale/en.yml
- #{RAILS_FRAMEWORK_ROOT}/activerecord/lib/active_record/locale/en.yml
- #{RAILS_FRAMEWORK_ROOT}/actionpack/lib/action_view/locale/en.yml
- #{RAILS_FRAMEWORK_ROOT}/railties/tmp/app/config/locales/en.yml
- my/other/locale.yml
- ).map { |path| File.expand_path(path) }, I18n.load_path.map { |path| File.expand_path(path) }
- end
-
- test "i18n finds locale files in engines" do
- # app_file "vendor/plugins/engine/init.rb", ""
- # app_file "vendor/plugins/engine/app/models/hellos.rb", "class Hello ; end"
- # app_file "vendor/plugins/engine/lib/omg.rb", "puts 'omg'"
- # app_file "vendor/plugins/engine/config/locales/en.yml", "hello:"
- #
- # Rails::Initializer.run do |c|
- # c.root = app_path
- # c.i18n.load_path << "my/other/locale.yml"
- # end
- # Rails.initialize!
- #
- # #{RAILS_FRAMEWORK_ROOT}/railties/test/fixtures/plugins/engines/engine/config/locales/en.yml
- # assert_equal %W(
- # #{RAILS_FRAMEWORK_ROOT}/activesupport/lib/active_support/locale/en.yml
- # #{RAILS_FRAMEWORK_ROOT}/activemodel/lib/active_model/locale/en.yml
- # #{RAILS_FRAMEWORK_ROOT}/activerecord/lib/active_record/locale/en.yml
- # #{RAILS_FRAMEWORK_ROOT}/actionpack/lib/action_view/locale/en.yml
- # #{app_path}/config/locales/en.yml
- # my/other/locale.yml
- # #{app_path}/vendor/plugins/engine/config/locales/en.yml
- # ).map { |path| File.expand_path(path) }, I18n.load_path.map { |path| File.expand_path(path) }
- end
- end
-end \ No newline at end of file
diff --git a/railties/test/isolation/abstract_unit.rb b/railties/test/isolation/abstract_unit.rb
index dc5fddb19d..940585836c 100644
--- a/railties/test/isolation/abstract_unit.rb
+++ b/railties/test/isolation/abstract_unit.rb
@@ -100,6 +100,8 @@ module TestHelpers
end
class Bukkit
+ attr_reader :path
+
def initialize(path)
@path = path
end
@@ -118,10 +120,29 @@ module TestHelpers
def plugin(name, string = "")
dir = "#{app_path}/vendor/plugins/#{name}"
FileUtils.mkdir_p(dir)
+
File.open("#{dir}/init.rb", 'w') do |f|
f.puts "::#{name.upcase} = 'loaded'"
f.puts string
end
+
+ Bukkit.new(dir).tap do |bukkit|
+ yield bukkit if block_given?
+ end
+ end
+
+ def engine(name)
+ dir = "#{app_path}/random/#{name}"
+ FileUtils.mkdir_p(dir)
+
+ app = File.readlines("#{app_path}/config/application.rb")
+ app.insert(2, "$:.unshift(\"#{dir}/lib\")")
+ app.insert(3, "require #{name.inspect}")
+
+ File.open("#{app_path}/config/application.rb", 'r+') do |f|
+ f.puts app
+ end
+
Bukkit.new(dir).tap do |bukkit|
yield bukkit if block_given?
end
diff --git a/railties/test/mocks/routes.rb b/railties/test/mocks/routes.rb
deleted file mode 100644
index ea12863683..0000000000
--- a/railties/test/mocks/routes.rb
+++ /dev/null
@@ -1,6 +0,0 @@
-module ActionController
- module Routing
- class Routes
- end
- end
-end
diff --git a/railties/test/paths_test.rb b/railties/test/paths_test.rb
index d60d6177f6..92c7b2ba0e 100644
--- a/railties/test/paths_test.rb
+++ b/railties/test/paths_test.rb
@@ -3,22 +3,23 @@ require 'rails/paths'
class PathsTest < ActiveSupport::TestCase
def setup
- @root = Rails::Application::Root.new("/foo/bar")
+ File.stubs(:exists?).returns(true)
+ @root = Rails::Paths::Root.new("/foo/bar")
end
test "the paths object is initialized with the root path" do
- root = Rails::Application::Root.new("/fiz/baz")
+ root = Rails::Paths::Root.new("/fiz/baz")
assert_equal "/fiz/baz", root.path
end
test "the paths object can be initialized with nil" do
assert_nothing_raised do
- Rails::Application::Root.new(nil)
+ Rails::Paths::Root.new(nil)
end
end
test "a paths object initialized with nil can be updated" do
- root = Rails::Application::Root.new(nil)
+ root = Rails::Paths::Root.new(nil)
root.app = "app"
root.path = "/root"
assert_equal ["/root/app"], root.app.to_a
@@ -30,7 +31,7 @@ class PathsTest < ActiveSupport::TestCase
end
test "raises exception if root path never set" do
- root = Rails::Application::Root.new(nil)
+ root = Rails::Paths::Root.new(nil)
root.app = "app"
assert_raises RuntimeError do
root.app.to_a
@@ -110,7 +111,7 @@ class PathsTest < ActiveSupport::TestCase
end
test "the root can only have one physical path" do
- assert_raise(RuntimeError) { Rails::Application::Root.new(["/fiz", "/biz"]) }
+ assert_raise(RuntimeError) { Rails::Paths::Root.new(["/fiz", "/biz"]) }
assert_raise(RuntimeError) { @root.push "/biz" }
assert_raise(RuntimeError) { @root.unshift "/biz" }
assert_raise(RuntimeError) { @root.concat ["/biz"]}
@@ -193,12 +194,7 @@ class PathsTest < ActiveSupport::TestCase
assert_equal 2, @root.eager_load.size
end
- test "a path should have a glob that defaults to **/*.rb" do
- @root.app = "/app"
- assert_equal "**/*.rb", @root.app.glob
- end
-
- test "it should be possible to override a path's default glob" do
+ test "it should be possible to add a path's default glob" do
@root.app = "/app"
@root.app.glob = "*.rb"
assert_equal "*.rb", @root.app.glob
@@ -227,4 +223,11 @@ class PathsTest < ActiveSupport::TestCase
@root.app.eager_load!
assert_equal ["/foo/bar/app"], @root.load_paths
end
+
+ test "adding a path to the load once paths also adds it to the load path" do
+ @root.app = "app"
+ @root.app.load_once!
+ assert_equal ["/foo/bar/app"], @root.load_paths
+ end
+
end
diff --git a/railties/test/plugins/configuration_test.rb b/railties/test/plugins/configuration_test.rb
deleted file mode 100644
index 09f8943af9..0000000000
--- a/railties/test/plugins/configuration_test.rb
+++ /dev/null
@@ -1,45 +0,0 @@
-require "isolation/abstract_unit"
-
-module PluginsTest
- class ConfigurationTest < Test::Unit::TestCase
- def setup
- build_app
- boot_rails
- require "rails/all"
- end
-
- test "config is available to plugins" do
- class Foo < Rails::Railtie ; end
- assert_nil Foo.config.action_controller.foo
- end
-
- test "a config name is available for the plugin" do
- class Foo < Rails::Railtie ; config.foo.greetings = "hello" ; end
- assert_equal "hello", Foo.config.foo.greetings
- end
-
- test "plugin configurations are available in the application" do
- class Foo < Rails::Railtie ; config.foo.greetings = "hello" ; end
- require "#{app_path}/config/application"
- assert_equal "hello", AppTemplate::Application.config.foo.greetings
- end
-
- test "plugin config merges are deep" do
- class Foo < Rails::Railtie ; config.foo.greetings = 'hello' ; end
- class MyApp < Rails::Application
- config.foo.bar = "bar"
- end
- assert_equal "hello", MyApp.config.foo.greetings
- assert_equal "bar", MyApp.config.foo.bar
- end
-
- test "plugin can add subscribers" do
- begin
- class Foo < Rails::Railtie; subscriber(Rails::Subscriber.new); end
- assert_kind_of Rails::Subscriber, Rails::Subscriber.subscribers[:foo]
- ensure
- Rails::Subscriber.subscribers.clear
- end
- end
- end
-end
diff --git a/railties/test/plugins/framework_extension_test.rb b/railties/test/plugins/framework_extension_test.rb
deleted file mode 100644
index d57fd4e635..0000000000
--- a/railties/test/plugins/framework_extension_test.rb
+++ /dev/null
@@ -1,68 +0,0 @@
-require "isolation/abstract_unit"
-
-module PluginsTest
- class FrameworkExtensionTest < Test::Unit::TestCase
- include ActiveSupport::Testing::Isolation
-
- def setup
- build_app
- boot_rails
- FileUtils.rm_rf("#{app_path}/config/environments")
- require "rails/all"
- end
-
- test "rake_tasks block is executed when MyApp.load_tasks is called" do
- $ran_block = false
-
- class MyTie < Rails::Railtie
- rake_tasks do
- $ran_block = true
- end
- end
-
- require "#{app_path}/config/environment"
-
- assert !$ran_block
- require 'rake'
- require 'rake/testtask'
- require 'rake/rdoctask'
-
- AppTemplate::Application.load_tasks
- assert $ran_block
- end
-
- test "generators block is executed when MyApp.load_generators is called" do
- $ran_block = false
-
- class MyTie < Rails::Railtie
- generators do
- $ran_block = true
- end
- end
-
- require "#{app_path}/config/environment"
-
- assert !$ran_block
- AppTemplate::Application.load_generators
- assert $ran_block
- end
- end
-
- class ActiveRecordExtensionTest < Test::Unit::TestCase
- include ActiveSupport::Testing::Isolation
-
- def setup
- build_app
- boot_rails
- FileUtils.rm_rf("#{app_path}/config/environments")
- end
-
- test "active_record extensions are applied to ActiveRecord" do
- add_to_config "config.active_record.table_name_prefix = 'tbl_'"
-
- require "#{app_path}/config/environment"
-
- assert_equal 'tbl_', ActiveRecord::Base.table_name_prefix
- end
- end
-end \ No newline at end of file
diff --git a/railties/test/plugins/vendored_test.rb b/railties/test/plugins/vendored_test.rb
deleted file mode 100644
index b3b85891b2..0000000000
--- a/railties/test/plugins/vendored_test.rb
+++ /dev/null
@@ -1,201 +0,0 @@
-require "isolation/abstract_unit"
-
-module PluginsTest
- class VendoredTest < Test::Unit::TestCase
- include ActiveSupport::Testing::Isolation
-
- def setup
- build_app
-
- @plugin = plugin "bukkits", "::LEVEL = config.log_level" do |plugin|
- plugin.write "lib/bukkits.rb", "class Bukkits; end"
- end
- end
-
- def boot_rails
- super
- require "#{app_path}/config/environment"
- end
-
- test "it loads the plugin's init.rb file" do
- boot_rails
- assert_equal "loaded", BUKKITS
- end
-
- test "the init.rb file has access to the config object" do
- boot_rails
- assert_equal :debug, LEVEL
- end
-
- test "the plugin puts its lib directory on the load path" do
- boot_rails
- require "bukkits"
- assert_equal "Bukkits", Bukkits.name
- end
-
- test "plugin paths get added to the AS::Dependency list" do
- boot_rails
- assert_equal "Bukkits", Bukkits.name
- end
-
- test "plugin constants do not get reloaded by default" do
- boot_rails
- assert_equal "Bukkits", Bukkits.name
- ActiveSupport::Dependencies.clear
- @plugin.delete("lib/bukkits.rb")
- assert_nothing_raised { Bukkits }
- end
-
- test "plugin constants get reloaded if config.reload_plugins is set" do
- add_to_config <<-RUBY
- config.reload_plugins = true
- RUBY
-
- boot_rails
-
- assert_equal "Bukkits", Bukkits.name
- ActiveSupport::Dependencies.clear
- @plugin.delete("lib/bukkits.rb")
- assert_raises(NameError) { Bukkits }
- end
-
- test "plugin should work without init.rb" do
- @plugin.delete("init.rb")
-
- boot_rails
-
- require "bukkits"
- assert_nothing_raised { Bukkits }
- end
-
- test "the plugin puts its models directory on the load path" do
- @plugin.write "app/models/my_bukkit.rb", "class MyBukkit ; end"
-
- boot_rails
-
- assert_nothing_raised { MyBukkit }
- end
-
- test "the plugin puts is controllers directory on the load path" do
- @plugin.write "app/controllers/bukkit_controller.rb", "class BukkitController ; end"
-
- boot_rails
-
- assert_nothing_raised { BukkitController }
- end
-
- test "the plugin adds its view to the load path" do
- @plugin.write "app/controllers/bukkit_controller.rb", <<-RUBY
- class BukkitController < ActionController::Base
- def index
- end
- end
- RUBY
-
- @plugin.write "app/views/bukkit/index.html.erb", "Hello bukkits"
-
- boot_rails
-
- require "action_controller"
- require "rack/mock"
- response = BukkitController.action(:index).call(Rack::MockRequest.env_for("/"))
- assert_equal "Hello bukkits\n", response[2].body
- end
-
- test "the plugin adds helpers to the controller's views" do
- @plugin.write "app/controllers/bukkit_controller.rb", <<-RUBY
- class BukkitController < ActionController::Base
- def index
- end
- end
- RUBY
-
- @plugin.write "app/helpers/bukkit_helper.rb", <<-RUBY
- module BukkitHelper
- def bukkits
- "bukkits"
- end
- end
- RUBY
-
- @plugin.write "app/views/bukkit/index.html.erb", "Hello <%= bukkits %>"
-
- boot_rails
-
- require "rack/mock"
- response = BukkitController.action(:index).call(Rack::MockRequest.env_for("/"))
- assert_equal "Hello bukkits\n", response[2].body
- end
-
- test "routes.rb are added to the router" do
- @plugin.write "config/routes.rb", <<-RUBY
- class Sprokkit
- def self.call(env)
- [200, {'Content-Type' => 'text/html'}, ["I am a Sprokkit"]]
- end
- end
-
- ActionController::Routing::Routes.draw do
- match "/sprokkit", :to => Sprokkit
- end
- RUBY
-
- boot_rails
- require "rack/mock"
- response = Rails.application.call(Rack::MockRequest.env_for("/sprokkit"))
- assert_equal "I am a Sprokkit", response[2].join
- end
- end
-
- class VendoredOrderingTest < Test::Unit::TestCase
- include ActiveSupport::Testing::Isolation
-
- def setup
- build_app
- $arr = []
- plugin "a_plugin", "$arr << :a"
- plugin "b_plugin", "$arr << :b"
- plugin "c_plugin", "$arr << :c"
- end
-
- def boot_rails
- super
- require "#{app_path}/config/environment"
- end
-
- test "plugins are loaded alphabetically by default" do
- boot_rails
- assert_equal [:a, :b, :c], $arr
- end
-
- test "if specified, only those plugins are loaded" do
- add_to_config "config.plugins = [:b_plugin]"
- boot_rails
- assert_equal [:b], $arr
- end
-
- test "the plugins are initialized in the order they are specified" do
- add_to_config "config.plugins = [:b_plugin, :a_plugin]"
- boot_rails
- assert_equal [:b, :a], $arr
- end
-
- test "if :all is specified, the remaining plugins are loaded in alphabetical order" do
- add_to_config "config.plugins = [:c_plugin, :all]"
- boot_rails
- assert_equal [:c, :a, :b], $arr
- end
-
- test "if :all is at the beginning, it represents the plugins not otherwise specified" do
- add_to_config "config.plugins = [:all, :b_plugin]"
- boot_rails
- assert_equal [:a, :c, :b], $arr
- end
-
- test "plugin order array is strings" do
- add_to_config "config.plugins = %w( c_plugin all )"
- boot_rails
- assert_equal [:c, :a, :b], $arr
- end
- end
-end
diff --git a/railties/test/railties/engine_test.rb b/railties/test/railties/engine_test.rb
new file mode 100644
index 0000000000..40ac11fa03
--- /dev/null
+++ b/railties/test/railties/engine_test.rb
@@ -0,0 +1,32 @@
+require "isolation/abstract_unit"
+require "railties/shared_tests"
+
+module RailtiesTest
+ class EngineTest < Test::Unit::TestCase
+ include ActiveSupport::Testing::Isolation
+ include SharedTests
+
+ def setup
+ build_app
+
+ @plugin = engine "bukkits" do |plugin|
+ plugin.write "lib/bukkits.rb", <<-RUBY
+ class Bukkits
+ class Engine < ::Rails::Engine
+ end
+ end
+ RUBY
+ plugin.write "lib/another.rb", "class Another; end"
+ end
+ end
+
+ def reload_config
+ :reload_engines
+ end
+
+ test "Rails::Engine itself does not respond to config" do
+ boot_rails
+ assert !Rails::Engine.respond_to?(:config)
+ end
+ end
+end
diff --git a/railties/test/railties/plugin_ordering_test.rb b/railties/test/railties/plugin_ordering_test.rb
new file mode 100644
index 0000000000..f6ca493fdf
--- /dev/null
+++ b/railties/test/railties/plugin_ordering_test.rb
@@ -0,0 +1,72 @@
+require "isolation/abstract_unit"
+
+module RailtiesTest
+ class PluginOrderingTest < Test::Unit::TestCase
+ include ActiveSupport::Testing::Isolation
+
+ def setup
+ build_app
+ $arr = []
+ plugin "a_plugin", "$arr << :a"
+ plugin "b_plugin", "$arr << :b"
+ plugin "c_plugin", "$arr << :c"
+ end
+
+ def boot_rails
+ super
+ require "#{app_path}/config/environment"
+ end
+
+ test "plugins are loaded alphabetically by default" do
+ boot_rails
+ assert_equal [:a, :b, :c], $arr
+ end
+
+ test "if specified, only those plugins are loaded" do
+ add_to_config "config.plugins = [:b_plugin]"
+ boot_rails
+ assert_equal [:b], $arr
+ end
+
+ test "the plugins are initialized in the order they are specified" do
+ add_to_config "config.plugins = [:b_plugin, :a_plugin]"
+ boot_rails
+ assert_equal [:b, :a], $arr
+ end
+
+ test "if :all is specified, the remaining plugins are loaded in alphabetical order" do
+ add_to_config "config.plugins = [:c_plugin, :all]"
+ boot_rails
+ assert_equal [:c, :a, :b], $arr
+ end
+
+ test "if :all is at the beginning, it represents the plugins not otherwise specified" do
+ add_to_config "config.plugins = [:all, :b_plugin]"
+ boot_rails
+ assert_equal [:a, :c, :b], $arr
+ end
+
+ test "plugin order array is strings" do
+ add_to_config "config.plugins = %w( c_plugin all )"
+ boot_rails
+ assert_equal [:c, :a, :b], $arr
+ end
+
+ test "can require lib file from a different plugin" do
+ plugin "foo", "require 'bar'" do |plugin|
+ plugin.write "lib/foo.rb", "$foo = true"
+ end
+
+ plugin "bar", "require 'foo'" do |plugin|
+ plugin.write "lib/bar.rb", "$bar = true"
+ end
+
+ add_to_config "config.plugins = [:foo, :bar]"
+
+ boot_rails
+
+ assert $foo
+ assert $bar
+ end
+ end
+end \ No newline at end of file
diff --git a/railties/test/railties/plugin_test.rb b/railties/test/railties/plugin_test.rb
new file mode 100644
index 0000000000..997b692e49
--- /dev/null
+++ b/railties/test/railties/plugin_test.rb
@@ -0,0 +1,115 @@
+require "isolation/abstract_unit"
+require "railties/shared_tests"
+
+module RailtiesTest
+ class PluginTest < Test::Unit::TestCase
+ include ActiveSupport::Testing::Isolation
+ include SharedTests
+
+ def setup
+ build_app
+
+ @plugin = plugin "bukkits", "::LEVEL = config.log_level" do |plugin|
+ plugin.write "lib/bukkits.rb", "class Bukkits; end"
+ plugin.write "lib/another.rb", "class Another; end"
+ end
+ end
+
+ def reload_config
+ :reload_plugins
+ end
+
+ test "Rails::Plugin itself does not respond to config" do
+ boot_rails
+ assert !Rails::Plugin.respond_to?(:config)
+ end
+
+ test "cannot inherit from Rails::Plugin" do
+ boot_rails
+ assert_raise RuntimeError do
+ class Foo < Rails::Plugin; end
+ end
+ end
+
+ test "plugin can load the file with the same name in lib" do
+ boot_rails
+ require "bukkits"
+ assert_equal "Bukkits", Bukkits.name
+ end
+
+ test "it loads the plugin's init.rb file" do
+ boot_rails
+ assert_equal "loaded", BUKKITS
+ end
+
+ test "the init.rb file has access to the config object" do
+ boot_rails
+ assert_equal :debug, LEVEL
+ end
+
+ test "plugin_init_is_ran_before_application_ones" do
+ plugin "foo", "$foo = true" do |plugin|
+ plugin.write "lib/foo.rb", "module Foo; end"
+ end
+
+ app_file 'config/initializers/foo.rb', <<-RUBY
+ raise "no $foo" unless $foo
+ raise "no Foo" unless Foo
+ RUBY
+
+ boot_rails
+ assert $foo
+ end
+
+ test "plugin should work without init.rb" do
+ @plugin.delete("init.rb")
+
+ boot_rails
+
+ require "bukkits"
+ assert_nothing_raised { Bukkits }
+ end
+
+ test "plugin cannot declare an engine for it" do
+ @plugin.write "lib/bukkits.rb", <<-RUBY
+ class Bukkits
+ class Engine < Rails::Engine
+ end
+ end
+ RUBY
+
+ @plugin.write "init.rb", <<-RUBY
+ require "bukkits"
+ RUBY
+
+ rescued = false
+
+ begin
+ boot_rails
+ rescue Exception => e
+ rescued = true
+ assert_equal '"bukkits" is a Railtie/Engine and cannot be installed as plugin', e.message
+ end
+
+ assert rescued, "Expected boot rails to fail"
+ end
+
+ test "deprecated tasks are also loaded" do
+ $executed = false
+ @plugin.write "tasks/foo.rake", <<-RUBY
+ task :foo do
+ $executed = true
+ end
+ RUBY
+
+ boot_rails
+ require 'rake'
+ require 'rake/rdoctask'
+ require 'rake/testtask'
+ Rails.application.load_tasks
+ Rake::Task[:foo].invoke
+ assert $executed
+ end
+
+ end
+end
diff --git a/railties/test/railties/railtie_test.rb b/railties/test/railties/railtie_test.rb
new file mode 100644
index 0000000000..b723e08281
--- /dev/null
+++ b/railties/test/railties/railtie_test.rb
@@ -0,0 +1,132 @@
+require "isolation/abstract_unit"
+
+module RailtiesTest
+ class RailtieTest < Test::Unit::TestCase
+ include ActiveSupport::Testing::Isolation
+
+ def setup
+ build_app
+ boot_rails
+ FileUtils.rm_rf("#{app_path}/config/environments")
+ require "rails/all"
+ end
+
+ def app
+ @app ||= Rails.application
+ end
+
+ test "Rails::Railtie itself does not respond to config" do
+ assert !Rails::Railtie.respond_to?(:config)
+ end
+
+ test "cannot inherit from a railtie" do
+ class Foo < Rails::Railtie ; end
+ assert_raise RuntimeError do
+ class Bar < Foo; end
+ end
+ end
+
+ test "config is available to railtie" do
+ class Foo < Rails::Railtie ; end
+ assert_nil Foo.config.action_controller.foo
+ end
+
+ test "config name is available for the railtie" do
+ class Foo < Rails::Railtie ; config.foo.greetings = "hello" ; end
+ assert_equal "hello", Foo.config.foo.greetings
+ end
+
+ test "railtie configurations are available in the application" do
+ class Foo < Rails::Railtie ; config.foo.greetings = "hello" ; end
+ require "#{app_path}/config/application"
+ assert_equal "hello", AppTemplate::Application.config.foo.greetings
+ end
+
+ test "railtie config merges are deep" do
+ class Foo < Rails::Railtie ; config.foo.greetings = 'hello' ; end
+ class Bar < Rails::Railtie
+ config.foo.bar = "bar"
+ end
+ assert_equal "hello", Bar.config.foo.greetings
+ assert_equal "bar", Bar.config.foo.bar
+ end
+
+ test "railtie can add subscribers" do
+ begin
+ class Foo < Rails::Railtie ; subscriber(Rails::Subscriber.new) ; end
+ assert_kind_of Rails::Subscriber, Rails::Subscriber.subscribers[:foo]
+ ensure
+ Rails::Subscriber.subscribers.clear
+ end
+ end
+
+ test "railtie can add to_prepare callbacks" do
+ $to_prepare = false
+ class Foo < Rails::Railtie ; config.to_prepare { $to_prepare = true } ; end
+ assert !$to_prepare
+ require "#{app_path}/config/environment"
+ require "rack/test"
+ extend Rack::Test::Methods
+ get "/"
+ assert $to_prepare
+ end
+
+ test "railtie can add after_initialize callbacks" do
+ $after_initialize = false
+ class Foo < Rails::Railtie ; config.after_initialize { $after_initialize = true } ; end
+ assert !$after_initialize
+ require "#{app_path}/config/environment"
+ assert $after_initialize
+ end
+
+ test "rake_tasks block is executed when MyApp.load_tasks is called" do
+ $ran_block = false
+
+ class MyTie < Rails::Railtie
+ rake_tasks do
+ $ran_block = true
+ end
+ end
+
+ require "#{app_path}/config/environment"
+
+ assert !$ran_block
+ require 'rake'
+ require 'rake/testtask'
+ require 'rake/rdoctask'
+
+ AppTemplate::Application.load_tasks
+ assert $ran_block
+ end
+
+ test "generators block is executed when MyApp.load_generators is called" do
+ $ran_block = false
+
+ class MyTie < Rails::Railtie
+ generators do
+ $ran_block = true
+ end
+ end
+
+ require "#{app_path}/config/environment"
+
+ assert !$ran_block
+ AppTemplate::Application.load_generators
+ assert $ran_block
+ end
+
+ test "railtie can add initializers" do
+ $ran_block = false
+
+ class MyTie < Rails::Railtie
+ initializer :something_nice do
+ $ran_block = true
+ end
+ end
+
+ assert !$ran_block
+ require "#{app_path}/config/environment"
+ assert $ran_block
+ end
+ end
+end
diff --git a/railties/test/railties/shared_tests.rb b/railties/test/railties/shared_tests.rb
new file mode 100644
index 0000000000..d51a0d153c
--- /dev/null
+++ b/railties/test/railties/shared_tests.rb
@@ -0,0 +1,315 @@
+module RailtiesTest
+ # Holds tests shared between plugin and engines
+ module SharedTests
+ def boot_rails
+ super
+ require "#{app_path}/config/environment"
+ end
+
+ def app
+ @app ||= Rails.application
+ end
+
+ def test_plugin_puts_its_lib_directory_on_load_path
+ boot_rails
+ require "another"
+ assert_equal "Another", Another.name
+ end
+
+ def test_plugin_paths_get_added_to_as_dependency_list
+ boot_rails
+ assert_equal "Another", Another.name
+ end
+
+ def test_plugins_constants_are_not_reloaded_by_default
+ boot_rails
+ assert_equal "Another", Another.name
+ ActiveSupport::Dependencies.clear
+ @plugin.delete("lib/another.rb")
+ assert_nothing_raised { Another }
+ end
+
+ def test_plugin_constants_get_reloaded_if_config_reload_plugins
+ add_to_config <<-RUBY
+ config.#{reload_config} = true
+ RUBY
+
+ boot_rails
+
+ assert_equal "Another", Another.name
+ ActiveSupport::Dependencies.clear
+ @plugin.delete("lib/another.rb")
+ assert_raises(NameError) { Another }
+ end
+
+ def test_plugin_puts_its_models_directory_on_load_path
+ @plugin.write "app/models/my_bukkit.rb", "class MyBukkit ; end"
+ boot_rails
+ assert_nothing_raised { MyBukkit }
+ end
+
+ def test_plugin_puts_its_controllers_directory_on_the_load_path
+ @plugin.write "app/controllers/bukkit_controller.rb", "class BukkitController ; end"
+ boot_rails
+ assert_nothing_raised { BukkitController }
+ end
+
+ def test_plugin_adds_its_views_to_view_paths
+ @plugin.write "app/controllers/bukkit_controller.rb", <<-RUBY
+ class BukkitController < ActionController::Base
+ def index
+ end
+ end
+ RUBY
+
+ @plugin.write "app/views/bukkit/index.html.erb", "Hello bukkits"
+
+ boot_rails
+
+ require "action_controller"
+ require "rack/mock"
+ response = BukkitController.action(:index).call(Rack::MockRequest.env_for("/"))
+ assert_equal "Hello bukkits\n", response[2].body
+ end
+
+ def test_plugin_adds_its_views_to_view_paths_with_lower_proriority
+ @plugin.write "app/controllers/bukkit_controller.rb", <<-RUBY
+ class BukkitController < ActionController::Base
+ def index
+ end
+ end
+ RUBY
+
+ @plugin.write "app/views/bukkit/index.html.erb", "Hello bukkits"
+ app_file "app/views/bukkit/index.html.erb", "Hi bukkits"
+
+ boot_rails
+
+ require "action_controller"
+ require "rack/mock"
+ response = BukkitController.action(:index).call(Rack::MockRequest.env_for("/"))
+ assert_equal "Hi bukkits\n", response[2].body
+ end
+
+ def test_plugin_adds_helpers_to_controller_views
+ @plugin.write "app/controllers/bukkit_controller.rb", <<-RUBY
+ class BukkitController < ActionController::Base
+ def index
+ end
+ end
+ RUBY
+
+ @plugin.write "app/helpers/bukkit_helper.rb", <<-RUBY
+ module BukkitHelper
+ def bukkits
+ "bukkits"
+ end
+ end
+ RUBY
+
+ @plugin.write "app/views/bukkit/index.html.erb", "Hello <%= bukkits %>"
+
+ boot_rails
+
+ require "rack/mock"
+ response = BukkitController.action(:index).call(Rack::MockRequest.env_for("/"))
+ assert_equal "Hello bukkits\n", response[2].body
+ end
+
+ def test_plugin_eager_load_any_path_under_app
+ @plugin.write "app/anything/foo.rb", <<-RUBY
+ module Foo; end
+ RUBY
+
+ boot_rails
+ assert Foo
+ end
+
+ def test_routes_are_added_to_router
+ @plugin.write "config/routes.rb", <<-RUBY
+ class Sprokkit
+ def self.call(env)
+ [200, {'Content-Type' => 'text/html'}, ["I am a Sprokkit"]]
+ end
+ end
+
+ ActionController::Routing::Routes.draw do
+ match "/sprokkit", :to => Sprokkit
+ end
+ RUBY
+
+ boot_rails
+ require 'rack/test'
+ extend Rack::Test::Methods
+
+ get "/sprokkit"
+ assert_equal "I am a Sprokkit", last_response.body
+ end
+
+ def test_routes_in_plugins_have_lower_priority_than_application_ones
+ controller "foo", <<-RUBY
+ class FooController < ActionController::Base
+ def index
+ render :text => "foo"
+ end
+ end
+ RUBY
+
+ app_file "config/routes.rb", <<-RUBY
+ AppTemplate::Application.routes.draw do |map|
+ match 'foo', :to => 'foo#index'
+ end
+ RUBY
+
+ @plugin.write "app/controllers/bar_controller.rb", <<-RUBY
+ class BarController < ActionController::Base
+ def index
+ render :text => "bar"
+ end
+ end
+ RUBY
+
+ @plugin.write "config/routes.rb", <<-RUBY
+ ActionController::Routing::Routes.draw do |map|
+ match 'foo', :to => 'bar#index'
+ match 'bar', :to => 'bar#index'
+ end
+ RUBY
+
+ boot_rails
+ require 'rack/test'
+ extend Rack::Test::Methods
+
+ get '/foo'
+ assert_equal 'foo', last_response.body
+
+ get '/bar'
+ assert_equal 'bar', last_response.body
+ end
+
+ def test_rake_tasks_lib_tasks_are_loaded
+ $executed = false
+ @plugin.write "lib/tasks/foo.rake", <<-RUBY
+ task :foo do
+ $executed = true
+ end
+ RUBY
+
+ boot_rails
+ require 'rake'
+ require 'rake/rdoctask'
+ require 'rake/testtask'
+ Rails.application.load_tasks
+ Rake::Task[:foo].invoke
+ assert $executed
+ end
+
+ def test_i18n_files_have_lower_priority_than_application_ones
+ add_to_config <<-RUBY
+ config.i18n.load_path << "#{app_path}/app/locales/en.yml"
+ RUBY
+
+ app_file 'app/locales/en.yml', <<-YAML
+en:
+ bar: "1"
+YAML
+
+ app_file 'config/locales/en.yml', <<-YAML
+en:
+ foo: "2"
+ bar: "2"
+YAML
+
+ @plugin.write 'config/locales/en.yml', <<-YAML
+en:
+ foo: "3"
+YAML
+
+ boot_rails
+
+ assert_equal %W(
+ #{RAILS_FRAMEWORK_ROOT}/activesupport/lib/active_support/locale/en.yml
+ #{RAILS_FRAMEWORK_ROOT}/activemodel/lib/active_model/locale/en.yml
+ #{RAILS_FRAMEWORK_ROOT}/activerecord/lib/active_record/locale/en.yml
+ #{RAILS_FRAMEWORK_ROOT}/actionpack/lib/action_view/locale/en.yml
+ #{@plugin.path}/config/locales/en.yml
+ #{app_path}/config/locales/en.yml
+ #{app_path}/app/locales/en.yml
+ ).map { |path| File.expand_path(path) }, I18n.load_path.map { |path| File.expand_path(path) }
+
+ assert_equal "2", I18n.t(:foo)
+ assert_equal "1", I18n.t(:bar)
+ end
+
+ def test_plugin_metals_added_to_middleware_stack
+ @plugin.write 'app/metal/foo_metal.rb', <<-RUBY
+ class FooMetal
+ def self.call(env)
+ [200, { "Content-Type" => "text/html"}, ["FooMetal"]]
+ end
+ end
+ RUBY
+
+ boot_rails
+ require 'rack/test'
+ extend Rack::Test::Methods
+
+ get "/"
+ assert_equal 200, last_response.status
+ assert_equal "FooMetal", last_response.body
+ end
+
+ def test_namespaced_controllers_with_namespaced_routes
+ @plugin.write "config/routes.rb", <<-RUBY
+ ActionController::Routing::Routes.draw do
+ namespace :admin do
+ match "index", :to => "admin/foo#index"
+ end
+ end
+ RUBY
+
+ @plugin.write "app/controllers/admin/foo_controller.rb", <<-RUBY
+ class Admin::FooController < ApplicationController
+ def index
+ render :text => "Rendered from namespace"
+ end
+ end
+ RUBY
+
+ boot_rails
+ require 'rack/test'
+ extend Rack::Test::Methods
+
+ get "/admin/index"
+ assert_equal 200, last_response.status
+ assert_equal "Rendered from namespace", last_response.body
+ end
+
+ def test_plugin_initializers
+ $plugin_initializer = false
+ @plugin.write "config/initializers/foo.rb", <<-RUBY
+ $plugin_initializer = true
+ RUBY
+
+ boot_rails
+ assert $plugin_initializer
+ end
+
+ def test_plugin_midleware_referenced_in_configuration
+ @plugin.write "lib/bukkits.rb", <<-RUBY
+ class Bukkits
+ def initialize(app)
+ @app = app
+ end
+
+ def call(env)
+ @app.call(env)
+ end
+ end
+ RUBY
+
+ add_to_config "config.middleware.use \"Bukkits\""
+ boot_rails
+ end
+ end
+end \ No newline at end of file
diff --git a/railties/test/vendor/gems/dummy-gem-a-0.4.0/.specification b/railties/test/vendor/gems/dummy-gem-a-0.4.0/.specification
deleted file mode 100644
index 86dba2092c..0000000000
--- a/railties/test/vendor/gems/dummy-gem-a-0.4.0/.specification
+++ /dev/null
@@ -1,28 +0,0 @@
---- !ruby/object:Gem::Specification
-name: dummy-gem-a
-version: !ruby/object:Gem::Version
- version: 0.4.0
-platform: ruby
-authors:
-- "Nobody"
-date: 2008-10-03 00:00:00 -04:00
-files:
-- lib
-- lib/dummy-gem-a.rb
-require_paths:
-- lib
-required_ruby_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-required_rubygems_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-requirements: []
-specification_version: 2
-summary: Dummy Gem A
diff --git a/railties/test/vendor/gems/dummy-gem-a-0.4.0/lib/dummy-gem-a.rb b/railties/test/vendor/gems/dummy-gem-a-0.4.0/lib/dummy-gem-a.rb
deleted file mode 100644
index 0453b38ab8..0000000000
--- a/railties/test/vendor/gems/dummy-gem-a-0.4.0/lib/dummy-gem-a.rb
+++ /dev/null
@@ -1 +0,0 @@
-DUMMY_GEM_A_VERSION="0.4.0"
diff --git a/railties/test/vendor/gems/dummy-gem-b-0.4.0/.specification b/railties/test/vendor/gems/dummy-gem-b-0.4.0/.specification
deleted file mode 100644
index 5ea692d7a1..0000000000
--- a/railties/test/vendor/gems/dummy-gem-b-0.4.0/.specification
+++ /dev/null
@@ -1,28 +0,0 @@
---- !ruby/object:Gem::Specification
-name: dummy-gem-b
-version: !ruby/object:Gem::Version
- version: 0.4.0
-platform: ruby
-authors:
-- "Nobody"
-date: 2008-10-03 00:00:00 -04:00
-files:
-- lib
-- lib/dummy-gem-b.rb
-require_paths:
-- lib
-required_ruby_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-required_rubygems_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-requirements: []
-specification_version: 2
-summary: Dummy Gem B
diff --git a/railties/test/vendor/gems/dummy-gem-b-0.4.0/lib/dummy-gem-b.rb b/railties/test/vendor/gems/dummy-gem-b-0.4.0/lib/dummy-gem-b.rb
deleted file mode 100644
index 850b5dda83..0000000000
--- a/railties/test/vendor/gems/dummy-gem-b-0.4.0/lib/dummy-gem-b.rb
+++ /dev/null
@@ -1 +0,0 @@
-DUMMY_GEM_B_VERSION="0.4.0"
diff --git a/railties/test/vendor/gems/dummy-gem-b-0.6.0/.specification b/railties/test/vendor/gems/dummy-gem-b-0.6.0/.specification
deleted file mode 100644
index ab4707124a..0000000000
--- a/railties/test/vendor/gems/dummy-gem-b-0.6.0/.specification
+++ /dev/null
@@ -1,28 +0,0 @@
---- !ruby/object:Gem::Specification
-name: dummy-gem-b
-version: !ruby/object:Gem::Version
- version: 0.6.0
-platform: ruby
-authors:
-- "Nobody"
-date: 2008-10-03 00:00:00 -04:00
-files:
-- lib
-- lib/dummy-gem-b.rb
-require_paths:
-- lib
-required_ruby_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-required_rubygems_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-requirements: []
-specification_version: 2
-summary: Dummy Gem B
diff --git a/railties/test/vendor/gems/dummy-gem-b-0.6.0/lib/dummy-gem-b.rb b/railties/test/vendor/gems/dummy-gem-b-0.6.0/lib/dummy-gem-b.rb
deleted file mode 100644
index 7d6d01cd48..0000000000
--- a/railties/test/vendor/gems/dummy-gem-b-0.6.0/lib/dummy-gem-b.rb
+++ /dev/null
@@ -1 +0,0 @@
-DUMMY_GEM_B_VERSION="0.6.0"
diff --git a/railties/test/vendor/gems/dummy-gem-c-0.4.0/.specification b/railties/test/vendor/gems/dummy-gem-c-0.4.0/.specification
deleted file mode 100644
index f90f60424c..0000000000
--- a/railties/test/vendor/gems/dummy-gem-c-0.4.0/.specification
+++ /dev/null
@@ -1,28 +0,0 @@
---- !ruby/object:Gem::Specification
-name: dummy-gem-c
-version: !ruby/object:Gem::Version
- version: 0.4.0
-platform: ruby
-authors:
-- "Nobody"
-date: 2008-10-03 00:00:00 -04:00
-files:
-- lib
-- lib/dummy-gem-c.rb
-require_paths:
-- lib
-required_ruby_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-required_rubygems_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-requirements: []
-specification_version: 2
-summary: Dummy Gem C
diff --git a/railties/test/vendor/gems/dummy-gem-c-0.4.0/lib/dummy-gem-c.rb b/railties/test/vendor/gems/dummy-gem-c-0.4.0/lib/dummy-gem-c.rb
deleted file mode 100644
index 1a416bef82..0000000000
--- a/railties/test/vendor/gems/dummy-gem-c-0.4.0/lib/dummy-gem-c.rb
+++ /dev/null
@@ -1 +0,0 @@
-DUMMY_GEM_C_VERSION="0.4.0"
diff --git a/railties/test/vendor/gems/dummy-gem-c-0.6.0/.specification b/railties/test/vendor/gems/dummy-gem-c-0.6.0/.specification
deleted file mode 100644
index e75c0aa66a..0000000000
--- a/railties/test/vendor/gems/dummy-gem-c-0.6.0/.specification
+++ /dev/null
@@ -1,28 +0,0 @@
---- !ruby/object:Gem::Specification
-name: dummy-gem-c
-version: !ruby/object:Gem::Version
- version: 0.6.0
-platform: ruby
-authors:
-- "Nobody"
-date: 2008-10-03 00:00:00 -04:00
-files:
-- lib
-- lib/dummy-gem-c.rb
-require_paths:
-- lib
-required_ruby_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-required_rubygems_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-requirements: []
-specification_version: 2
-summary: Dummy Gem C
diff --git a/railties/test/vendor/gems/dummy-gem-c-0.6.0/lib/dummy-gem-c.rb b/railties/test/vendor/gems/dummy-gem-c-0.6.0/lib/dummy-gem-c.rb
deleted file mode 100644
index 9ba2ca8bb5..0000000000
--- a/railties/test/vendor/gems/dummy-gem-c-0.6.0/lib/dummy-gem-c.rb
+++ /dev/null
@@ -1 +0,0 @@
-DUMMY_GEM_C_VERSION="0.6.0"
diff --git a/railties/test/vendor/gems/dummy-gem-d-1.0.0/lib/dummy-gem-d.rb b/railties/test/vendor/gems/dummy-gem-d-1.0.0/lib/dummy-gem-d.rb
deleted file mode 100644
index e5cb007e5f..0000000000
--- a/railties/test/vendor/gems/dummy-gem-d-1.0.0/lib/dummy-gem-d.rb
+++ /dev/null
@@ -1 +0,0 @@
-DUMMY_GEM_D_VERSION="1.0.0"
diff --git a/railties/test/vendor/gems/dummy-gem-e-1.0.0/.specification b/railties/test/vendor/gems/dummy-gem-e-1.0.0/.specification
deleted file mode 100644
index ce4443c8be..0000000000
--- a/railties/test/vendor/gems/dummy-gem-e-1.0.0/.specification
+++ /dev/null
@@ -1,28 +0,0 @@
---- !ruby/object:Gem::Specification
-name: dummy-gem-e
-version: !ruby/object:Gem::Version
- version: 1.3.0
-platform: ruby
-authors:
-- "Nobody"
-date: 2008-10-03 00:00:00 -04:00
-files:
-- lib
-- lib/dummy-gem-e.rb
-require_paths:
-- lib
-required_ruby_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-required_rubygems_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-requirements: []
-specification_version: 2
-summary: Dummy Gem E
diff --git a/railties/test/vendor/gems/dummy-gem-e-1.0.0/lib/dummy-gem-e.rb b/railties/test/vendor/gems/dummy-gem-e-1.0.0/lib/dummy-gem-e.rb
deleted file mode 100644
index 48bf91a701..0000000000
--- a/railties/test/vendor/gems/dummy-gem-e-1.0.0/lib/dummy-gem-e.rb
+++ /dev/null
@@ -1 +0,0 @@
-DUMMY_GEM_E_VERSION="1.0.0"
diff --git a/railties/test/vendor/gems/dummy-gem-f-1.0.0/.specification b/railties/test/vendor/gems/dummy-gem-f-1.0.0/.specification
deleted file mode 100644
index 70a36b9a8c..0000000000
--- a/railties/test/vendor/gems/dummy-gem-f-1.0.0/.specification
+++ /dev/null
@@ -1,39 +0,0 @@
---- !ruby/object:Gem::Specification
-name: dummy-gem-f
-version: !ruby/object:Gem::Version
- version: 1.3.0
-platform: ruby
-authors:
-- "Nobody"
-date: 2008-10-03 00:00:00 -04:00
-dependencies:
-- !ruby/object:Gem::Dependency
- name: absolutely-no-such-gem
- type: :runtime
- version_requirement:
- version_requirements: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: 1.0.0
- version:
-files:
-- lib
-- lib/dummy-gem-f.rb
-require_paths:
-- lib
-required_ruby_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-required_rubygems_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-requirements: []
-specification_version: 2
-summary: Dummy Gem F
diff --git a/railties/test/vendor/gems/dummy-gem-f-1.0.0/lib/dummy-gem-f.rb b/railties/test/vendor/gems/dummy-gem-f-1.0.0/lib/dummy-gem-f.rb
deleted file mode 100644
index 0271c8c48a..0000000000
--- a/railties/test/vendor/gems/dummy-gem-f-1.0.0/lib/dummy-gem-f.rb
+++ /dev/null
@@ -1 +0,0 @@
-DUMMY_GEM_F_VERSION="1.0.0"
diff --git a/railties/test/vendor/gems/dummy-gem-g-1.0.0/.specification b/railties/test/vendor/gems/dummy-gem-g-1.0.0/.specification
deleted file mode 100644
index 27e29912a6..0000000000
--- a/railties/test/vendor/gems/dummy-gem-g-1.0.0/.specification
+++ /dev/null
@@ -1,39 +0,0 @@
---- !ruby/object:Gem::Specification
-name: dummy-gem-g
-version: !ruby/object:Gem::Version
- version: 1.3.0
-platform: ruby
-authors:
-- "Nobody"
-date: 2008-10-03 00:00:00 -04:00
-dependencies:
-- !ruby/object:Gem::Dependency
- name: dummy-gem-f
- type: :runtime
- version_requirement:
- version_requirements: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: 1.0.0
- version:
-files:
-- lib
-- lib/dummy-gem-g.rb
-require_paths:
-- lib
-required_ruby_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-required_rubygems_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-requirements: []
-specification_version: 2
-summary: Dummy Gem G
diff --git a/railties/test/vendor/gems/dummy-gem-g-1.0.0/lib/dummy-gem-g.rb b/railties/test/vendor/gems/dummy-gem-g-1.0.0/lib/dummy-gem-g.rb
deleted file mode 100644
index 8fc056586c..0000000000
--- a/railties/test/vendor/gems/dummy-gem-g-1.0.0/lib/dummy-gem-g.rb
+++ /dev/null
@@ -1 +0,0 @@
-DUMMY_GEM_G_VERSION="1.0.0"
diff --git a/railties/test/vendor/gems/dummy-gem-h-1.0.0/.specification b/railties/test/vendor/gems/dummy-gem-h-1.0.0/.specification
deleted file mode 100644
index b3f7930948..0000000000
--- a/railties/test/vendor/gems/dummy-gem-h-1.0.0/.specification
+++ /dev/null
@@ -1,29 +0,0 @@
---- !ruby/object:Gem::Specification
-name: dummy-gem-h
-version: !ruby/object:Gem::Version
- version: 1.3.0
-platform: ruby
-authors:
-- "Nobody"
-date: 2008-10-03 00:00:00 -04:00
-dependencies:
-files:
-- lib
-- lib/dummy-gem-h.rb
-require_paths:
-- lib
-required_ruby_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-required_rubygems_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-requirements: []
-specification_version: 2
-summary: Dummy Gem H
diff --git a/railties/test/vendor/gems/dummy-gem-h-1.0.0/lib/dummy-gem-h.rb b/railties/test/vendor/gems/dummy-gem-h-1.0.0/lib/dummy-gem-h.rb
deleted file mode 100644
index 0f91234936..0000000000
--- a/railties/test/vendor/gems/dummy-gem-h-1.0.0/lib/dummy-gem-h.rb
+++ /dev/null
@@ -1 +0,0 @@
-DUMMY_GEM_H_VERSION="1.0.0"
diff --git a/railties/test/vendor/gems/dummy-gem-i-1.0.0/.specification b/railties/test/vendor/gems/dummy-gem-i-1.0.0/.specification
deleted file mode 100644
index 50b4969da5..0000000000
--- a/railties/test/vendor/gems/dummy-gem-i-1.0.0/.specification
+++ /dev/null
@@ -1,41 +0,0 @@
---- !ruby/object:Gem::Specification
-name: dummy-gem-i
-version: !ruby/object:Gem::Version
- version: 1.3.0
-platform: ruby
-authors:
-- "Nobody"
-date: 2008-10-03 00:00:00 -04:00
-dependencies:
-- !ruby/object:Gem::Dependency
- name: dummy-gem-i
- type: :runtime
- version_requirement:
- version_requirements: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: 1.0.0
- version:
-extensions:
-- ext/dummy-gem-i/extconf.rb
-files:
-- lib
-- lib/dummy-gem-i.rb
-require_paths:
-- lib
-required_ruby_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-required_rubygems_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-requirements: []
-specification_version: 2
-summary: Dummy Gem G
diff --git a/railties/test/vendor/gems/dummy-gem-i-1.0.0/ext/dummy-gem-i/Makefile b/railties/test/vendor/gems/dummy-gem-i-1.0.0/ext/dummy-gem-i/Makefile
deleted file mode 100644
index e69de29bb2..0000000000
--- a/railties/test/vendor/gems/dummy-gem-i-1.0.0/ext/dummy-gem-i/Makefile
+++ /dev/null
diff --git a/railties/test/vendor/gems/dummy-gem-i-1.0.0/lib/dummy-gem-i.rb b/railties/test/vendor/gems/dummy-gem-i-1.0.0/lib/dummy-gem-i.rb
deleted file mode 100644
index 2f9a376c2c..0000000000
--- a/railties/test/vendor/gems/dummy-gem-i-1.0.0/lib/dummy-gem-i.rb
+++ /dev/null
@@ -1 +0,0 @@
-DUMMY_GEM_I_VERSION="1.0.0"
diff --git a/railties/test/vendor/gems/dummy-gem-j-1.0.0/.specification b/railties/test/vendor/gems/dummy-gem-j-1.0.0/.specification
deleted file mode 100644
index 2c456546fc..0000000000
--- a/railties/test/vendor/gems/dummy-gem-j-1.0.0/.specification
+++ /dev/null
@@ -1,41 +0,0 @@
---- !ruby/object:Gem::Specification
-name: dummy-gem-j
-version: !ruby/object:Gem::Version
- version: 1.3.0
-platform: ruby
-authors:
-- "Nobody"
-date: 2008-10-03 00:00:00 -04:00
-dependencies:
-- !ruby/object:Gem::Dependency
- name: dummy-gem-j
- type: :runtime
- version_requirement:
- version_requirements: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: 1.0.0
- version:
-extensions:
-- ext/dummy-gem-j/extconf.rb
-files:
-- lib
-- lib/dummy-gem-j.rb
-require_paths:
-- lib
-required_ruby_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-required_rubygems_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-requirements: []
-specification_version: 2
-summary: Dummy Gem G
diff --git a/railties/test/vendor/gems/dummy-gem-j-1.0.0/lib/dummy-gem-j.rb b/railties/test/vendor/gems/dummy-gem-j-1.0.0/lib/dummy-gem-j.rb
deleted file mode 100644
index 8ecd363ff8..0000000000
--- a/railties/test/vendor/gems/dummy-gem-j-1.0.0/lib/dummy-gem-j.rb
+++ /dev/null
@@ -1 +0,0 @@
-DUMMY_GEM_J_VERSION="1.0.0"
diff --git a/railties/test/vendor/gems/dummy-gem-k-1.0.0/.specification b/railties/test/vendor/gems/dummy-gem-k-1.0.0/.specification
deleted file mode 100644
index 20edd0f856..0000000000
--- a/railties/test/vendor/gems/dummy-gem-k-1.0.0/.specification
+++ /dev/null
@@ -1,49 +0,0 @@
---- !ruby/object:Gem::Specification
-name: dummy-gem-k
-version: !ruby/object:Gem::Version
- version: 1.3.0
-platform: ruby
-authors:
-- "Nobody"
-date: 2008-10-03 00:00:00 -04:00
-dependencies:
-- !ruby/object:Gem::Dependency
- name: dummy-gem-k
- type: :runtime
- version_requirement:
- version_requirements: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: 1.0.0
- version:
-- !ruby/object:Gem::Dependency
- name: dummy-gem-h
- type: :development
- version_requirement:
- version_requirements: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: 1.0.0
- version:
-files:
-- lib
-- lib/dummy-gem-k.rb
-require_paths:
-- lib
-required_ruby_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-required_rubygems_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-requirements: []
-specification_version: 2
-summary: Dummy Gem I
diff --git a/railties/test/vendor/gems/dummy-gem-k-1.0.0/lib/dummy-gem-k.rb b/railties/test/vendor/gems/dummy-gem-k-1.0.0/lib/dummy-gem-k.rb
deleted file mode 100644
index 97fb1d69ce..0000000000
--- a/railties/test/vendor/gems/dummy-gem-k-1.0.0/lib/dummy-gem-k.rb
+++ /dev/null
@@ -1 +0,0 @@
-DUMMY_GEM_K_VERSION="1.0.0"