income-tax 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.rspec +4 -0
- data/Gemfile +11 -0
- data/Gemfile.lock +60 -0
- data/LICENSE +22 -0
- data/income-tax.gemspec +12 -0
- data/lib/income-tax.rb +1 -0
- data/lib/income_tax/countries/afghanistan.rb +10 -0
- data/lib/income_tax/countries/aland.rb +10 -0
- data/lib/income_tax/countries/albania.rb +12 -0
- data/lib/income_tax/countries/algeria.rb +13 -0
- data/lib/income_tax/countries/american_samoa.rb +10 -0
- data/lib/income_tax/countries/andorra.rb +9 -0
- data/lib/income_tax/countries/angola.rb +23 -0
- data/lib/income_tax/countries/anguilla.rb +8 -0
- data/lib/income_tax/countries/antigua_and_barbuda.rb +11 -0
- data/lib/income_tax/countries/argentina.rb +16 -0
- data/lib/income_tax/countries/armenia.rb +11 -0
- data/lib/income_tax/countries/aruba.rb +23 -0
- data/lib/income_tax/countries/australia.rb +32 -0
- data/lib/income_tax/countries/austria.rb +14 -0
- data/lib/income_tax/countries/azerbaijan.rb +11 -0
- data/lib/income_tax/countries/bahamas.rb +8 -0
- data/lib/income_tax/countries/bahrain.rb +8 -0
- data/lib/income_tax/countries/bangladesh.rb +42 -0
- data/lib/income_tax/countries/barbados.rb +28 -0
- data/lib/income_tax/countries/belarus.rb +9 -0
- data/lib/income_tax/countries/belgium.rb +14 -0
- data/lib/income_tax/countries/belize.rb +11 -0
- data/lib/income_tax/countries/benin.rb +13 -0
- data/lib/income_tax/countries/bermuda.rb +8 -0
- data/lib/income_tax/countries/bhutan.rb +14 -0
- data/lib/income_tax/countries/bolivia.rb +9 -0
- data/lib/income_tax/countries/bosnia_and_herzegovina.rb +9 -0
- data/lib/income_tax/countries/botswana.rb +11 -0
- data/lib/income_tax/countries/bouvet_island.rb +10 -0
- data/lib/income_tax/countries/brazil.rb +14 -0
- data/lib/income_tax/countries/british_indian_ocean_territory.rb +10 -0
- data/lib/income_tax/countries/brunei.rb +8 -0
- data/lib/income_tax/countries/bulgaria.rb +9 -0
- data/lib/income_tax/countries/burkina_faso.rb +16 -0
- data/lib/income_tax/countries/burundi.rb +12 -0
- data/lib/income_tax/countries/cambodia.rb +14 -0
- data/lib/income_tax/countries/cameroon.rb +13 -0
- data/lib/income_tax/countries/canada.rb +13 -0
- data/lib/income_tax/countries/cape_verde.rb +14 -0
- data/lib/income_tax/countries/caribbean_netherlands.rb +15 -0
- data/lib/income_tax/countries/cayman_islands.rb +8 -0
- data/lib/income_tax/countries/central_african_republic.rb +11 -0
- data/lib/income_tax/countries/chad.rb +17 -0
- data/lib/income_tax/countries/chile.rb +20 -0
- data/lib/income_tax/countries/china.rb +17 -0
- data/lib/income_tax/countries/christmas_island.rb +8 -0
- data/lib/income_tax/countries/cocos_keeling_islands.rb +8 -0
- data/lib/income_tax/countries/colombia.rb +14 -0
- data/lib/income_tax/countries/comoros.rb +16 -0
- data/lib/income_tax/countries/congo.rb +9 -0
- data/lib/income_tax/countries/congo_republic.rb +14 -0
- data/lib/income_tax/countries/cook_islands.rb +13 -0
- data/lib/income_tax/countries/costa_rica.rb +30 -0
- data/lib/income_tax/countries/croatia.rb +12 -0
- data/lib/income_tax/countries/cuba.rb +12 -0
- data/lib/income_tax/countries/curacao.rb +15 -0
- data/lib/income_tax/countries/cyprus.rb +14 -0
- data/lib/income_tax/countries/czech_republic.rb +9 -0
- data/lib/income_tax/countries/denmark.rb +12 -0
- data/lib/income_tax/countries/djibouti.rb +14 -0
- data/lib/income_tax/countries/dominica.rb +13 -0
- data/lib/income_tax/countries/dominican_republic.rb +13 -0
- data/lib/income_tax/countries/ecuador.rb +18 -0
- data/lib/income_tax/countries/egypt.rb +14 -0
- data/lib/income_tax/countries/el_salvador.rb +9 -0
- data/lib/income_tax/countries/equatorial_guinea.rb +16 -0
- data/lib/income_tax/countries/eritrea.rb +9 -0
- data/lib/income_tax/countries/estonia.rb +9 -0
- data/lib/income_tax/countries/ethiopia.rb +16 -0
- data/lib/income_tax/countries/falkland_islands.rb +12 -0
- data/lib/income_tax/countries/faroe_islands.rb +9 -0
- data/lib/income_tax/countries/fiji.rb +20 -0
- data/lib/income_tax/countries/finland.rb +14 -0
- data/lib/income_tax/countries/france.rb +34 -0
- data/lib/income_tax/countries/french_guiana.rb +8 -0
- data/lib/income_tax/countries/french_polynesia.rb +8 -0
- data/lib/income_tax/countries/french_southern_territories.rb +8 -0
- data/lib/income_tax/countries/gabon.rb +17 -0
- data/lib/income_tax/countries/gambia.rb +15 -0
- data/lib/income_tax/countries/georgia.rb +9 -0
- data/lib/income_tax/countries/germany.rb +58 -0
- data/lib/income_tax/countries/ghana.rb +14 -0
- data/lib/income_tax/countries/gibraltar.rb +15 -0
- data/lib/income_tax/countries/greece.rb +11 -0
- data/lib/income_tax/countries/greenland.rb +9 -0
- data/lib/income_tax/countries/grenada.rb +11 -0
- data/lib/income_tax/countries/guadeloupe.rb +14 -0
- data/lib/income_tax/countries/guam.rb +10 -0
- data/lib/income_tax/countries/guatemala.rb +13 -0
- data/lib/income_tax/countries/guernsey.rb +9 -0
- data/lib/income_tax/countries/guinea.rb +13 -0
- data/lib/income_tax/countries/guinea_bissau.rb +9 -0
- data/lib/income_tax/countries/guyana.rb +11 -0
- data/lib/income_tax/countries/haiti.rb +9 -0
- data/lib/income_tax/countries/heard_and_mcdonald_islands.rb +8 -0
- data/lib/income_tax/countries/honduras.rb +9 -0
- data/lib/income_tax/countries/hong_kong.rb +15 -0
- data/lib/income_tax/countries/hungary.rb +9 -0
- data/lib/income_tax/countries/iceland.rb +12 -0
- data/lib/income_tax/countries/india.rb +14 -0
- data/lib/income_tax/countries/indonesia.rb +14 -0
- data/lib/income_tax/countries/iran.rb +14 -0
- data/lib/income_tax/countries/iraq.rb +9 -0
- data/lib/income_tax/countries/ireland.rb +24 -0
- data/lib/income_tax/countries/isle_of_man.rb +11 -0
- data/lib/income_tax/countries/israel.rb +16 -0
- data/lib/income_tax/countries/italy.rb +14 -0
- data/lib/income_tax/countries/ivory_coast.rb +14 -0
- data/lib/income_tax/countries/jamaica.rb +11 -0
- data/lib/income_tax/countries/japan.rb +15 -0
- data/lib/income_tax/countries/jersey.rb +9 -0
- data/lib/income_tax/countries/jordan.rb +14 -0
- data/lib/income_tax/countries/kazakhstan.rb +9 -0
- data/lib/income_tax/countries/kenya.rb +14 -0
- data/lib/income_tax/countries/kiribati.rb +9 -0
- data/lib/income_tax/countries/kosovo.rb +13 -0
- data/lib/income_tax/countries/kuwait.rb +8 -0
- data/lib/income_tax/countries/kyrgyzstan.rb +9 -0
- data/lib/income_tax/countries/laos.rb +15 -0
- data/lib/income_tax/countries/latvia.rb +9 -0
- data/lib/income_tax/countries/lebanon.rb +15 -0
- data/lib/income_tax/countries/lesotho.rb +13 -0
- data/lib/income_tax/countries/liberia.rb +13 -0
- data/lib/income_tax/countries/libya.rb +12 -0
- data/lib/income_tax/countries/liechtenstein.rb +9 -0
- data/lib/income_tax/countries/lithuania.rb +9 -0
- data/lib/income_tax/countries/luxembourg.rb +33 -0
- data/lib/income_tax/countries/macao.rb +19 -0
- data/lib/income_tax/countries/macedonia.rb +9 -0
- data/lib/income_tax/countries/madagascar.rb +11 -0
- data/lib/income_tax/countries/malawi.rb +12 -0
- data/lib/income_tax/countries/malaysia.rb +18 -0
- data/lib/income_tax/countries/maldives.rb +8 -0
- data/lib/income_tax/countries/mali.rb +9 -0
- data/lib/income_tax/countries/malta.rb +36 -0
- data/lib/income_tax/countries/marshall_islands.rb +11 -0
- data/lib/income_tax/countries/martinique.rb +14 -0
- data/lib/income_tax/countries/mauritania.rb +12 -0
- data/lib/income_tax/countries/mauritius.rb +9 -0
- data/lib/income_tax/countries/mayotte.rb +8 -0
- data/lib/income_tax/countries/mexico.rb +20 -0
- data/lib/income_tax/countries/micronesia.rb +9 -0
- data/lib/income_tax/countries/moldova.rb +13 -0
- data/lib/income_tax/countries/monaco.rb +9 -0
- data/lib/income_tax/countries/mongolia.rb +9 -0
- data/lib/income_tax/countries/montenegro.rb +11 -0
- data/lib/income_tax/countries/montserrat.rb +14 -0
- data/lib/income_tax/countries/morocco.rb +15 -0
- data/lib/income_tax/countries/mozambique.rb +14 -0
- data/lib/income_tax/countries/myanmar.rb +15 -0
- data/lib/income_tax/countries/namibia.rb +16 -0
- data/lib/income_tax/countries/nauru.rb +8 -0
- data/lib/income_tax/countries/nepal.rb +28 -0
- data/lib/income_tax/countries/netherlands.rb +13 -0
- data/lib/income_tax/countries/netherlands_antilles.rb +15 -0
- data/lib/income_tax/countries/new_caledonia.rb +14 -0
- data/lib/income_tax/countries/new_zealand.rb +13 -0
- data/lib/income_tax/countries/nicaragua.rb +32 -0
- data/lib/income_tax/countries/niger.rb +16 -0
- data/lib/income_tax/countries/nigeria.rb +15 -0
- data/lib/income_tax/countries/niue.rb +13 -0
- data/lib/income_tax/countries/norfolk_island.rb +9 -0
- data/lib/income_tax/countries/north_korea.rb +8 -0
- data/lib/income_tax/countries/northern_mariana_islands.rb +10 -0
- data/lib/income_tax/countries/norway.rb +13 -0
- data/lib/income_tax/countries/oman.rb +8 -0
- data/lib/income_tax/countries/pakistan.rb +21 -0
- data/lib/income_tax/countries/palau.rb +12 -0
- data/lib/income_tax/countries/palestinian_territory.rb +15 -0
- data/lib/income_tax/countries/panama.rb +12 -0
- data/lib/income_tax/countries/papua_new_guinea.rb +15 -0
- data/lib/income_tax/countries/paraguay.rb +9 -0
- data/lib/income_tax/countries/peru.rb +11 -0
- data/lib/income_tax/countries/philippines.rb +16 -0
- data/lib/income_tax/countries/pitcairn.rb +12 -0
- data/lib/income_tax/countries/poland.rb +12 -0
- data/lib/income_tax/countries/portugal.rb +14 -0
- data/lib/income_tax/countries/puerto_rico.rb +9 -0
- data/lib/income_tax/countries/qatar.rb +8 -0
- data/lib/income_tax/countries/reunion.rb +8 -0
- data/lib/income_tax/countries/romania.rb +9 -0
- data/lib/income_tax/countries/russia.rb +9 -0
- data/lib/income_tax/countries/rwanda.rb +12 -0
- data/lib/income_tax/countries/saint_barthelemy.rb +8 -0
- data/lib/income_tax/countries/saint_helena.rb +9 -0
- data/lib/income_tax/countries/saint_kitts_and_nevis.rb +8 -0
- data/lib/income_tax/countries/saint_lucia.rb +14 -0
- data/lib/income_tax/countries/saint_martin.rb +14 -0
- data/lib/income_tax/countries/saint_pierre_and_miquelon.rb +21 -0
- data/lib/income_tax/countries/saint_vincent_and_the_grenedines.rb +13 -0
- data/lib/income_tax/countries/samoa.rb +13 -0
- data/lib/income_tax/countries/san_marino.rb +17 -0
- data/lib/income_tax/countries/sao_tome_and_principe.rb +9 -0
- data/lib/income_tax/countries/saudi_arabia.rb +8 -0
- data/lib/income_tax/countries/senegal.rb +19 -0
- data/lib/income_tax/countries/serbia.rb +13 -0
- data/lib/income_tax/countries/seychelles.rb +9 -0
- data/lib/income_tax/countries/sierra_leone.rb +13 -0
- data/lib/income_tax/countries/singapore.rb +43 -0
- data/lib/income_tax/countries/sint_maarten.rb +15 -0
- data/lib/income_tax/countries/slovakia.rb +11 -0
- data/lib/income_tax/countries/slovenia.rb +13 -0
- data/lib/income_tax/countries/solomon_islands.rb +16 -0
- data/lib/income_tax/countries/somalia.rb +15 -0
- data/lib/income_tax/countries/south_africa.rb +15 -0
- data/lib/income_tax/countries/south_georgia_and_the_south_sandwich_islands.rb +10 -0
- data/lib/income_tax/countries/south_korea.rb +13 -0
- data/lib/income_tax/countries/south_sudan.rb +12 -0
- data/lib/income_tax/countries/spain.rb +14 -0
- data/lib/income_tax/countries/sri_lanka.rb +9 -0
- data/lib/income_tax/countries/sudan.rb +9 -0
- data/lib/income_tax/countries/suriname.rb +14 -0
- data/lib/income_tax/countries/svalbard_and_jan_mayen.rb +9 -0
- data/lib/income_tax/countries/swaziland.rb +9 -0
- data/lib/income_tax/countries/sweden.rb +12 -0
- data/lib/income_tax/countries/switzerland/aargau.rb +12 -0
- data/lib/income_tax/countries/switzerland/appenzell_inner.rb +12 -0
- data/lib/income_tax/countries/switzerland/appenzell_outer.rb +11 -0
- data/lib/income_tax/countries/switzerland/basel_city.rb +11 -0
- data/lib/income_tax/countries/switzerland/basel_land.rb +11 -0
- data/lib/income_tax/countries/switzerland/bern.rb +10 -0
- data/lib/income_tax/countries/switzerland/canton.rb +36 -0
- data/lib/income_tax/countries/switzerland/data/aargau.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/appenzell_inner.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/appenzell_outer.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/basel_city.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/basel_land.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/bern.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/fribourg.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/geneva.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/glarus.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/grisons.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/jura.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/lucerne.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/neuchatel.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/nidwalden.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/obwalden.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/schaffhausen.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/schwyz.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/solothurn.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/st_gallen.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/thurgau.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/ticino.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/uri.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/valais.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/vaud.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/zug.dat +0 -0
- data/lib/income_tax/countries/switzerland/data/zurich.dat +0 -0
- data/lib/income_tax/countries/switzerland/federal.rb +46 -0
- data/lib/income_tax/countries/switzerland/fribourg.rb +11 -0
- data/lib/income_tax/countries/switzerland/geneva.rb +12 -0
- data/lib/income_tax/countries/switzerland/glarus.rb +12 -0
- data/lib/income_tax/countries/switzerland/grisons.rb +11 -0
- data/lib/income_tax/countries/switzerland/jura.rb +11 -0
- data/lib/income_tax/countries/switzerland/lucerne.rb +11 -0
- data/lib/income_tax/countries/switzerland/neuchatel.rb +12 -0
- data/lib/income_tax/countries/switzerland/nidwalden.rb +11 -0
- data/lib/income_tax/countries/switzerland/obwalden.rb +11 -0
- data/lib/income_tax/countries/switzerland/schaffhausen.rb +12 -0
- data/lib/income_tax/countries/switzerland/schwyz.rb +11 -0
- data/lib/income_tax/countries/switzerland/solothurn.rb +12 -0
- data/lib/income_tax/countries/switzerland/st_gallen.rb +12 -0
- data/lib/income_tax/countries/switzerland/thurgau.rb +12 -0
- data/lib/income_tax/countries/switzerland/ticino.rb +11 -0
- data/lib/income_tax/countries/switzerland/uri.rb +11 -0
- data/lib/income_tax/countries/switzerland/valais.rb +10 -0
- data/lib/income_tax/countries/switzerland/vaud.rb +11 -0
- data/lib/income_tax/countries/switzerland/zug.rb +12 -0
- data/lib/income_tax/countries/switzerland/zurich.rb +12 -0
- data/lib/income_tax/countries/switzerland.rb +62 -0
- data/lib/income_tax/countries/syria.rb +12 -0
- data/lib/income_tax/countries/taiwan.rb +14 -0
- data/lib/income_tax/countries/tajikistan.rb +13 -0
- data/lib/income_tax/countries/tanzania.rb +53 -0
- data/lib/income_tax/countries/thailand.rb +17 -0
- data/lib/income_tax/countries/timor_leste.rb +11 -0
- data/lib/income_tax/countries/togo.rb +9 -0
- data/lib/income_tax/countries/tokelau.rb +15 -0
- data/lib/income_tax/countries/tonga.rb +12 -0
- data/lib/income_tax/countries/trinidad_and_tobago.rb +11 -0
- data/lib/income_tax/countries/tunisia.rb +15 -0
- data/lib/income_tax/countries/turkey.rb +13 -0
- data/lib/income_tax/countries/turkmenistan.rb +9 -0
- data/lib/income_tax/countries/turks_and_caicos_islands.rb +8 -0
- data/lib/income_tax/countries/tuvalu.rb +9 -0
- data/lib/income_tax/countries/uganda.rb +13 -0
- data/lib/income_tax/countries/ukraine.rb +9 -0
- data/lib/income_tax/countries/united_arab_emirates.rb +8 -0
- data/lib/income_tax/countries/united_kingdom.rb +13 -0
- data/lib/income_tax/countries/united_states/alabama.rb +24 -0
- data/lib/income_tax/countries/united_states/alaska.rb +10 -0
- data/lib/income_tax/countries/united_states/arizona.rb +29 -0
- data/lib/income_tax/countries/united_states/arkansas.rb +29 -0
- data/lib/income_tax/countries/united_states/california.rb +39 -0
- data/lib/income_tax/countries/united_states/colorado.rb +10 -0
- data/lib/income_tax/countries/united_states/connecticut.rb +31 -0
- data/lib/income_tax/countries/united_states/dc.rb +16 -0
- data/lib/income_tax/countries/united_states/delaware.rb +31 -0
- data/lib/income_tax/countries/united_states/federal.rb +40 -0
- data/lib/income_tax/countries/united_states/florida.rb +10 -0
- data/lib/income_tax/countries/united_states/georgia.rb +32 -0
- data/lib/income_tax/countries/united_states/hawaii.rb +43 -0
- data/lib/income_tax/countries/united_states/idaho.rb +34 -0
- data/lib/income_tax/countries/united_states/illinois.rb +10 -0
- data/lib/income_tax/countries/united_states/indiana.rb +10 -0
- data/lib/income_tax/countries/united_states/iowa.rb +39 -0
- data/lib/income_tax/countries/united_states/kansas.rb +23 -0
- data/lib/income_tax/countries/united_states/kentucky.rb +31 -0
- data/lib/income_tax/countries/united_states/louisiana.rb +26 -0
- data/lib/income_tax/countries/united_states/maine.rb +23 -0
- data/lib/income_tax/countries/united_states/maryland.rb +35 -0
- data/lib/income_tax/countries/united_states/massachusetts.rb +10 -0
- data/lib/income_tax/countries/united_states/michigan.rb +10 -0
- data/lib/income_tax/countries/united_states/minnesota.rb +27 -0
- data/lib/income_tax/countries/united_states/mississippi.rb +25 -0
- data/lib/income_tax/countries/united_states/missouri.rb +40 -0
- data/lib/income_tax/countries/united_states/montana.rb +34 -0
- data/lib/income_tax/countries/united_states/nebraska.rb +27 -0
- data/lib/income_tax/countries/united_states/nevada.rb +10 -0
- data/lib/income_tax/countries/united_states/new_hampshire.rb +10 -0
- data/lib/income_tax/countries/united_states/new_jersey.rb +32 -0
- data/lib/income_tax/countries/united_states/new_mexico.rb +27 -0
- data/lib/income_tax/countries/united_states/new_york.rb +35 -0
- data/lib/income_tax/countries/united_states/north_carolina.rb +10 -0
- data/lib/income_tax/countries/united_states/north_dakota.rb +17 -0
- data/lib/income_tax/countries/united_states/ohio.rb +37 -0
- data/lib/income_tax/countries/united_states/oklahoma.rb +33 -0
- data/lib/income_tax/countries/united_states/oregon.rb +28 -0
- data/lib/income_tax/countries/united_states/pennsylvania.rb +10 -0
- data/lib/income_tax/countries/united_states/rhode_island.rb +25 -0
- data/lib/income_tax/countries/united_states/south_carolina.rb +17 -0
- data/lib/income_tax/countries/united_states/south_dakota.rb +10 -0
- data/lib/income_tax/countries/united_states/state.rb +34 -0
- data/lib/income_tax/countries/united_states/tennessee.rb +10 -0
- data/lib/income_tax/countries/united_states/texas.rb +10 -0
- data/lib/income_tax/countries/united_states/utah.rb +10 -0
- data/lib/income_tax/countries/united_states/vermont.rb +29 -0
- data/lib/income_tax/countries/united_states/virginia.rb +16 -0
- data/lib/income_tax/countries/united_states/washington.rb +10 -0
- data/lib/income_tax/countries/united_states/west_virginia.rb +29 -0
- data/lib/income_tax/countries/united_states/wisconsin.rb +27 -0
- data/lib/income_tax/countries/united_states/wyoming.rb +10 -0
- data/lib/income_tax/countries/united_states.rb +93 -0
- data/lib/income_tax/countries/united_states_minor_outlying_islands.rb +8 -0
- data/lib/income_tax/countries/uruguay.rb +16 -0
- data/lib/income_tax/countries/uzbekistan.rb +15 -0
- data/lib/income_tax/countries/vanuatu.rb +8 -0
- data/lib/income_tax/countries/vatican.rb +8 -0
- data/lib/income_tax/countries/venezuela.rb +20 -0
- data/lib/income_tax/countries/vietnam.rb +17 -0
- data/lib/income_tax/countries/virgin_islands_british.rb +9 -0
- data/lib/income_tax/countries/virgin_islands_us.rb +8 -0
- data/lib/income_tax/countries/wallis_and_futuna.rb +8 -0
- data/lib/income_tax/countries/western_sahara.rb +8 -0
- data/lib/income_tax/countries/yemen.rb +11 -0
- data/lib/income_tax/countries/zambia.rb +13 -0
- data/lib/income_tax/countries/zimbabwe.rb +17 -0
- data/lib/income_tax/countries.rb +5 -0
- data/lib/income_tax/factory.rb +66 -0
- data/lib/income_tax/helpers.rb +25 -0
- data/lib/income_tax/models/delegate.rb +30 -0
- data/lib/income_tax/models/fixed_rate.rb +14 -0
- data/lib/income_tax/models/generic.rb +212 -0
- data/lib/income_tax/models/no_taxes.rb +7 -0
- data/lib/income_tax/models/not_implemented.rb +6 -0
- data/lib/income_tax/models/progressive.rb +103 -0
- data/lib/income_tax/models.rb +10 -0
- data/lib/income_tax/rate.rb +152 -0
- data/lib/income_tax/register.rb +35 -0
- data/lib/income_tax/version.rb +3 -0
- data/lib/income_tax.rb +17 -0
- data/locations.md +1763 -0
- data/readme.md +137 -0
- data/script/generate_switzerland.rb +87 -0
- data/spec/income_tax/countries/afghanistan_spec.rb +89 -0
- data/spec/income_tax/countries/aland_spec.rb +89 -0
- data/spec/income_tax/countries/albania_spec.rb +89 -0
- data/spec/income_tax/countries/algeria_spec.rb +89 -0
- data/spec/income_tax/countries/american_samoa_spec.rb +89 -0
- data/spec/income_tax/countries/andorra_spec.rb +89 -0
- data/spec/income_tax/countries/angola_spec.rb +89 -0
- data/spec/income_tax/countries/anguilla_spec.rb +89 -0
- data/spec/income_tax/countries/antigua_and_barbuda_spec.rb +89 -0
- data/spec/income_tax/countries/argentina_spec.rb +89 -0
- data/spec/income_tax/countries/armenia_spec.rb +89 -0
- data/spec/income_tax/countries/aruba_spec.rb +89 -0
- data/spec/income_tax/countries/australia_spec.rb +89 -0
- data/spec/income_tax/countries/austria_spec.rb +89 -0
- data/spec/income_tax/countries/azerbaijan_spec.rb +89 -0
- data/spec/income_tax/countries/bahamas_spec.rb +89 -0
- data/spec/income_tax/countries/bahrain_spec.rb +89 -0
- data/spec/income_tax/countries/bangladesh_spec.rb +89 -0
- data/spec/income_tax/countries/barbados_spec.rb +89 -0
- data/spec/income_tax/countries/belarus_spec.rb +89 -0
- data/spec/income_tax/countries/belgium_spec.rb +89 -0
- data/spec/income_tax/countries/belize_spec.rb +89 -0
- data/spec/income_tax/countries/benin_spec.rb +89 -0
- data/spec/income_tax/countries/bermuda_spec.rb +89 -0
- data/spec/income_tax/countries/bhutan_spec.rb +89 -0
- data/spec/income_tax/countries/bolivia_spec.rb +89 -0
- data/spec/income_tax/countries/bosnia_and_herzegovina_spec.rb +89 -0
- data/spec/income_tax/countries/botswana_spec.rb +89 -0
- data/spec/income_tax/countries/bouvet_island_spec.rb +89 -0
- data/spec/income_tax/countries/brazil_spec.rb +89 -0
- data/spec/income_tax/countries/british_indian_ocean_territory_spec.rb +89 -0
- data/spec/income_tax/countries/brunei_spec.rb +89 -0
- data/spec/income_tax/countries/bulgaria_spec.rb +89 -0
- data/spec/income_tax/countries/burkina_faso_spec.rb +89 -0
- data/spec/income_tax/countries/burundi_spec.rb +89 -0
- data/spec/income_tax/countries/cambodia_spec.rb +89 -0
- data/spec/income_tax/countries/cameroon_spec.rb +89 -0
- data/spec/income_tax/countries/canada_spec.rb +89 -0
- data/spec/income_tax/countries/cape_verde_spec.rb +89 -0
- data/spec/income_tax/countries/caribbean_netherlands_spec.rb +89 -0
- data/spec/income_tax/countries/cayman_islands_spec.rb +89 -0
- data/spec/income_tax/countries/central_african_republic_spec.rb +89 -0
- data/spec/income_tax/countries/chad_spec.rb +89 -0
- data/spec/income_tax/countries/chile_spec.rb +89 -0
- data/spec/income_tax/countries/china_spec.rb +89 -0
- data/spec/income_tax/countries/christmas_island_spec.rb +89 -0
- data/spec/income_tax/countries/cocos_keeling_islands_spec.rb +89 -0
- data/spec/income_tax/countries/colombia_spec.rb +89 -0
- data/spec/income_tax/countries/comoros_spec.rb +89 -0
- data/spec/income_tax/countries/congo_republic_spec.rb +89 -0
- data/spec/income_tax/countries/congo_spec.rb +89 -0
- data/spec/income_tax/countries/cook_islands_spec.rb +89 -0
- data/spec/income_tax/countries/costa_rica_spec.rb +89 -0
- data/spec/income_tax/countries/croatia_spec.rb +89 -0
- data/spec/income_tax/countries/cuba_spec.rb +89 -0
- data/spec/income_tax/countries/curacao_spec.rb +89 -0
- data/spec/income_tax/countries/cyprus_spec.rb +89 -0
- data/spec/income_tax/countries/czech_republic_spec.rb +89 -0
- data/spec/income_tax/countries/denmark_spec.rb +89 -0
- data/spec/income_tax/countries/djibouti_spec.rb +89 -0
- data/spec/income_tax/countries/dominica_spec.rb +89 -0
- data/spec/income_tax/countries/dominican_republic_spec.rb +89 -0
- data/spec/income_tax/countries/ecuador_spec.rb +89 -0
- data/spec/income_tax/countries/egypt_spec.rb +89 -0
- data/spec/income_tax/countries/el_salvador_spec.rb +89 -0
- data/spec/income_tax/countries/equatorial_guinea_spec.rb +89 -0
- data/spec/income_tax/countries/eritrea_spec.rb +89 -0
- data/spec/income_tax/countries/estonia_spec.rb +89 -0
- data/spec/income_tax/countries/ethiopia_spec.rb +89 -0
- data/spec/income_tax/countries/falkland_islands_spec.rb +89 -0
- data/spec/income_tax/countries/faroe_islands_spec.rb +89 -0
- data/spec/income_tax/countries/fiji_spec.rb +89 -0
- data/spec/income_tax/countries/finland_spec.rb +89 -0
- data/spec/income_tax/countries/france_spec.rb +89 -0
- data/spec/income_tax/countries/french_guiana_spec.rb +89 -0
- data/spec/income_tax/countries/french_polynesia_spec.rb +89 -0
- data/spec/income_tax/countries/french_southern_territories_spec.rb +89 -0
- data/spec/income_tax/countries/gabon_spec.rb +89 -0
- data/spec/income_tax/countries/gambia_spec.rb +89 -0
- data/spec/income_tax/countries/georgia_spec.rb +89 -0
- data/spec/income_tax/countries/germany_spec.rb +89 -0
- data/spec/income_tax/countries/ghana_spec.rb +89 -0
- data/spec/income_tax/countries/gibraltar_spec.rb +89 -0
- data/spec/income_tax/countries/greece_spec.rb +89 -0
- data/spec/income_tax/countries/greenland_spec.rb +89 -0
- data/spec/income_tax/countries/grenada_spec.rb +89 -0
- data/spec/income_tax/countries/guadeloupe_spec.rb +89 -0
- data/spec/income_tax/countries/guam_spec.rb +89 -0
- data/spec/income_tax/countries/guatemala_spec.rb +89 -0
- data/spec/income_tax/countries/guernsey_spec.rb +89 -0
- data/spec/income_tax/countries/guinea_bissau_spec.rb +89 -0
- data/spec/income_tax/countries/guinea_spec.rb +89 -0
- data/spec/income_tax/countries/guyana_spec.rb +89 -0
- data/spec/income_tax/countries/haiti_spec.rb +89 -0
- data/spec/income_tax/countries/heard_and_mcdonald_islands_spec.rb +89 -0
- data/spec/income_tax/countries/honduras_spec.rb +89 -0
- data/spec/income_tax/countries/hong_kong_spec.rb +89 -0
- data/spec/income_tax/countries/hungary_spec.rb +89 -0
- data/spec/income_tax/countries/iceland_spec.rb +89 -0
- data/spec/income_tax/countries/india_spec.rb +89 -0
- data/spec/income_tax/countries/indonesia_spec.rb +89 -0
- data/spec/income_tax/countries/iran_spec.rb +89 -0
- data/spec/income_tax/countries/iraq_spec.rb +89 -0
- data/spec/income_tax/countries/ireland_spec.rb +89 -0
- data/spec/income_tax/countries/isle_of_man_spec.rb +89 -0
- data/spec/income_tax/countries/israel_spec.rb +89 -0
- data/spec/income_tax/countries/italy_spec.rb +89 -0
- data/spec/income_tax/countries/ivory_coast_spec.rb +89 -0
- data/spec/income_tax/countries/jamaica_spec.rb +89 -0
- data/spec/income_tax/countries/japan_spec.rb +89 -0
- data/spec/income_tax/countries/jersey_spec.rb +89 -0
- data/spec/income_tax/countries/jordan_spec.rb +89 -0
- data/spec/income_tax/countries/kazakhstan_spec.rb +89 -0
- data/spec/income_tax/countries/kenya_spec.rb +89 -0
- data/spec/income_tax/countries/kiribati_spec.rb +89 -0
- data/spec/income_tax/countries/kosovo_spec.rb +89 -0
- data/spec/income_tax/countries/kuwait_spec.rb +89 -0
- data/spec/income_tax/countries/kyrgyzstan_spec.rb +89 -0
- data/spec/income_tax/countries/laos_spec.rb +89 -0
- data/spec/income_tax/countries/latvia_spec.rb +89 -0
- data/spec/income_tax/countries/lebanon_spec.rb +89 -0
- data/spec/income_tax/countries/lesotho_spec.rb +89 -0
- data/spec/income_tax/countries/liberia_spec.rb +89 -0
- data/spec/income_tax/countries/libya_spec.rb +89 -0
- data/spec/income_tax/countries/liechtenstein_spec.rb +89 -0
- data/spec/income_tax/countries/lithuania_spec.rb +89 -0
- data/spec/income_tax/countries/luxembourg_spec.rb +89 -0
- data/spec/income_tax/countries/macao_spec.rb +89 -0
- data/spec/income_tax/countries/macedonia_spec.rb +89 -0
- data/spec/income_tax/countries/madagascar_spec.rb +89 -0
- data/spec/income_tax/countries/malawi_spec.rb +89 -0
- data/spec/income_tax/countries/malaysia_spec.rb +89 -0
- data/spec/income_tax/countries/maldives_spec.rb +89 -0
- data/spec/income_tax/countries/mali_spec.rb +89 -0
- data/spec/income_tax/countries/malta_spec.rb +89 -0
- data/spec/income_tax/countries/marshall_islands_spec.rb +89 -0
- data/spec/income_tax/countries/martinique_spec.rb +89 -0
- data/spec/income_tax/countries/mauritania_spec.rb +89 -0
- data/spec/income_tax/countries/mauritius_spec.rb +89 -0
- data/spec/income_tax/countries/mayotte_spec.rb +89 -0
- data/spec/income_tax/countries/mexico_spec.rb +89 -0
- data/spec/income_tax/countries/micronesia_spec.rb +89 -0
- data/spec/income_tax/countries/moldova_spec.rb +89 -0
- data/spec/income_tax/countries/monaco_spec.rb +89 -0
- data/spec/income_tax/countries/mongolia_spec.rb +89 -0
- data/spec/income_tax/countries/montenegro_spec.rb +89 -0
- data/spec/income_tax/countries/montserrat_spec.rb +89 -0
- data/spec/income_tax/countries/morocco_spec.rb +89 -0
- data/spec/income_tax/countries/mozambique_spec.rb +89 -0
- data/spec/income_tax/countries/myanmar_spec.rb +89 -0
- data/spec/income_tax/countries/namibia_spec.rb +89 -0
- data/spec/income_tax/countries/nauru_spec.rb +89 -0
- data/spec/income_tax/countries/nepal_spec.rb +89 -0
- data/spec/income_tax/countries/netherlands_antilles_spec.rb +89 -0
- data/spec/income_tax/countries/netherlands_spec.rb +89 -0
- data/spec/income_tax/countries/new_caledonia_spec.rb +89 -0
- data/spec/income_tax/countries/new_zealand_spec.rb +89 -0
- data/spec/income_tax/countries/nicaragua_spec.rb +89 -0
- data/spec/income_tax/countries/niger_spec.rb +89 -0
- data/spec/income_tax/countries/nigeria_spec.rb +89 -0
- data/spec/income_tax/countries/niue_spec.rb +89 -0
- data/spec/income_tax/countries/norfolk_island_spec.rb +89 -0
- data/spec/income_tax/countries/north_korea_spec.rb +89 -0
- data/spec/income_tax/countries/northern_mariana_islands_spec.rb +89 -0
- data/spec/income_tax/countries/norway_spec.rb +89 -0
- data/spec/income_tax/countries/oman_spec.rb +89 -0
- data/spec/income_tax/countries/pakistan_spec.rb +89 -0
- data/spec/income_tax/countries/palau_spec.rb +89 -0
- data/spec/income_tax/countries/palestinian_territory_spec.rb +89 -0
- data/spec/income_tax/countries/panama_spec.rb +89 -0
- data/spec/income_tax/countries/papua_new_guinea_spec.rb +89 -0
- data/spec/income_tax/countries/paraguay_spec.rb +89 -0
- data/spec/income_tax/countries/peru_spec.rb +89 -0
- data/spec/income_tax/countries/philippines_spec.rb +89 -0
- data/spec/income_tax/countries/pitcairn_spec.rb +89 -0
- data/spec/income_tax/countries/poland_spec.rb +89 -0
- data/spec/income_tax/countries/portugal_spec.rb +89 -0
- data/spec/income_tax/countries/puerto_rico_spec.rb +89 -0
- data/spec/income_tax/countries/qatar_spec.rb +89 -0
- data/spec/income_tax/countries/reunion_spec.rb +89 -0
- data/spec/income_tax/countries/romania_spec.rb +89 -0
- data/spec/income_tax/countries/russia_spec.rb +89 -0
- data/spec/income_tax/countries/rwanda_spec.rb +89 -0
- data/spec/income_tax/countries/saint_barthelemy_spec.rb +89 -0
- data/spec/income_tax/countries/saint_helena_spec.rb +89 -0
- data/spec/income_tax/countries/saint_kitts_and_nevis_spec.rb +89 -0
- data/spec/income_tax/countries/saint_lucia_spec.rb +89 -0
- data/spec/income_tax/countries/saint_martin_spec.rb +89 -0
- data/spec/income_tax/countries/saint_pierre_and_miquelon_spec.rb +89 -0
- data/spec/income_tax/countries/saint_vincent_and_the_grenedines_spec.rb +89 -0
- data/spec/income_tax/countries/samoa_spec.rb +89 -0
- data/spec/income_tax/countries/san_marino_spec.rb +89 -0
- data/spec/income_tax/countries/sao_tome_and_principe_spec.rb +89 -0
- data/spec/income_tax/countries/saudi_arabia_spec.rb +89 -0
- data/spec/income_tax/countries/senegal_spec.rb +89 -0
- data/spec/income_tax/countries/serbia_spec.rb +89 -0
- data/spec/income_tax/countries/seychelles_spec.rb +89 -0
- data/spec/income_tax/countries/sierra_leone_spec.rb +89 -0
- data/spec/income_tax/countries/singapore_spec.rb +89 -0
- data/spec/income_tax/countries/sint_maarten_spec.rb +89 -0
- data/spec/income_tax/countries/slovakia_spec.rb +89 -0
- data/spec/income_tax/countries/slovenia_spec.rb +89 -0
- data/spec/income_tax/countries/solomon_islands_spec.rb +89 -0
- data/spec/income_tax/countries/somalia_spec.rb +89 -0
- data/spec/income_tax/countries/south_africa_spec.rb +89 -0
- data/spec/income_tax/countries/south_georgia_and_the_south_sandwich_islands_spec.rb +89 -0
- data/spec/income_tax/countries/south_korea_spec.rb +89 -0
- data/spec/income_tax/countries/south_sudan_spec.rb +89 -0
- data/spec/income_tax/countries/spain_spec.rb +89 -0
- data/spec/income_tax/countries/sri_lanka_spec.rb +89 -0
- data/spec/income_tax/countries/sudan_spec.rb +89 -0
- data/spec/income_tax/countries/suriname_spec.rb +89 -0
- data/spec/income_tax/countries/svalbard_and_jan_mayen_spec.rb +89 -0
- data/spec/income_tax/countries/swaziland_spec.rb +89 -0
- data/spec/income_tax/countries/sweden_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/aargau_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/appenzell_inner_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/appenzell_outer_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/basel_city_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/basel_land_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/bern_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/fribourg_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/geneva_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/glarus_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/grisons_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/jura_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/lucerne_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/neuchatel_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/nidwalden_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/obwalden_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/schaffhausen_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/schwyz_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/solothurn_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/st_gallen_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/thurgau_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/ticino_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/uri_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/valais_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/vaud_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/zug_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland/zurich_spec.rb +89 -0
- data/spec/income_tax/countries/switzerland_spec.rb +89 -0
- data/spec/income_tax/countries/syria_spec.rb +89 -0
- data/spec/income_tax/countries/taiwan_spec.rb +89 -0
- data/spec/income_tax/countries/tajikistan_spec.rb +89 -0
- data/spec/income_tax/countries/tanzania_spec.rb +89 -0
- data/spec/income_tax/countries/thailand_spec.rb +89 -0
- data/spec/income_tax/countries/timor_leste_spec.rb +89 -0
- data/spec/income_tax/countries/togo_spec.rb +89 -0
- data/spec/income_tax/countries/tokelau_spec.rb +89 -0
- data/spec/income_tax/countries/tonga_spec.rb +89 -0
- data/spec/income_tax/countries/trinidad_and_tobago_spec.rb +89 -0
- data/spec/income_tax/countries/tunisia_spec.rb +89 -0
- data/spec/income_tax/countries/turkey_spec.rb +89 -0
- data/spec/income_tax/countries/turkmenistan_spec.rb +89 -0
- data/spec/income_tax/countries/turks_and_caicos_islands_spec.rb +89 -0
- data/spec/income_tax/countries/tuvalu_spec.rb +89 -0
- data/spec/income_tax/countries/uganda_spec.rb +89 -0
- data/spec/income_tax/countries/ukraine_spec.rb +89 -0
- data/spec/income_tax/countries/united_arab_emirates_spec.rb +89 -0
- data/spec/income_tax/countries/united_kingdom_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/alabama_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/alaska_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/arizona_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/arkansas_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/california_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/colorado_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/connecticut_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/dc_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/delaware_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/florida_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/georgia_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/hawaii_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/idaho_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/illinois_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/indiana_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/iowa_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/kansas_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/kentucky_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/louisiana_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/maine_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/maryland_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/massachusetts_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/michigan_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/minnesota_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/mississippi_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/missouri_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/montana_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/nebraska_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/nevada_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/new_hampshire_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/new_jersey_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/new_mexico_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/new_york_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/north_carolina_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/north_dakota_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/ohio_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/oklahoma_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/oregon_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/pennsylvania_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/rhode_island_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/south_carolina_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/south_dakota_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/tennessee_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/texas_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/utah_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/vermont_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/virginia_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/washington_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/west_virginia_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/wisconsin_spec.rb +89 -0
- data/spec/income_tax/countries/united_states/wyoming_spec.rb +89 -0
- data/spec/income_tax/countries/united_states_minor_outlying_islands_spec.rb +89 -0
- data/spec/income_tax/countries/united_states_spec.rb +89 -0
- data/spec/income_tax/countries/uruguay_spec.rb +89 -0
- data/spec/income_tax/countries/uzbekistan_spec.rb +89 -0
- data/spec/income_tax/countries/vanuatu_spec.rb +89 -0
- data/spec/income_tax/countries/vatican_spec.rb +89 -0
- data/spec/income_tax/countries/venezuela_spec.rb +89 -0
- data/spec/income_tax/countries/vietnam_spec.rb +89 -0
- data/spec/income_tax/countries/virgin_islands_british_spec.rb +89 -0
- data/spec/income_tax/countries/virgin_islands_us_spec.rb +89 -0
- data/spec/income_tax/countries/wallis_and_futuna_spec.rb +89 -0
- data/spec/income_tax/countries/western_sahara_spec.rb +89 -0
- data/spec/income_tax/countries/yemen_spec.rb +89 -0
- data/spec/income_tax/countries/zambia_spec.rb +89 -0
- data/spec/income_tax/countries/zimbabwe_spec.rb +89 -0
- data/spec/income_tax/models/fixed_rate_spec.rb +24 -0
- data/spec/income_tax/models/no_taxes_spec.rb +20 -0
- data/spec/income_tax/models/progressive_spec.rb +98 -0
- data/spec/income_tax/rate_spec.rb +257 -0
- data/spec/income_tax/register_spec.rb +14 -0
- data/spec/income_tax_spec.rb +9 -0
- data/spec/support/coverage.rb +16 -0
- data/spec/support/env.rb +12 -0
- data/spec/support.rb +3 -0
- metadata +760 -0
@@ -0,0 +1,89 @@
|
|
1
|
+
describe IncomeTax::Countries::Senegal do
|
2
|
+
subject(:result) { described_class.new(income: income, income_type: type) }
|
3
|
+
let(:type) { :gross }
|
4
|
+
|
5
|
+
describe "from gross income of 0" do
|
6
|
+
let(:income) { 0 }
|
7
|
+
its(:rate) { should be == Rational(0, 1) }
|
8
|
+
its(:gross_income) { should be == 0 }
|
9
|
+
its(:net_income) { should be == 0 }
|
10
|
+
its(:taxes) { should be == 0 }
|
11
|
+
end
|
12
|
+
|
13
|
+
describe "from gross income of 1000" do
|
14
|
+
let(:income) { 1000 }
|
15
|
+
its(:rate) { should be == Rational(0, 1) }
|
16
|
+
its(:gross_income) { should be == 1000 }
|
17
|
+
its(:net_income) { should be == 1000 }
|
18
|
+
its(:taxes) { should be == 0 }
|
19
|
+
end
|
20
|
+
|
21
|
+
describe "from gross income of 10000" do
|
22
|
+
let(:income) { 10000 }
|
23
|
+
its(:rate) { should be == Rational(0, 1) }
|
24
|
+
its(:gross_income) { should be == 10000 }
|
25
|
+
its(:net_income) { should be == 10000 }
|
26
|
+
its(:taxes) { should be == 0 }
|
27
|
+
end
|
28
|
+
|
29
|
+
describe "from gross income of 100000" do
|
30
|
+
let(:income) { 100000 }
|
31
|
+
its(:rate) { should be == Rational(0, 1) }
|
32
|
+
its(:gross_income) { should be == 100000 }
|
33
|
+
its(:net_income) { should be == 100000 }
|
34
|
+
its(:taxes) { should be == 0 }
|
35
|
+
end
|
36
|
+
|
37
|
+
describe "from gross income of 100000000" do
|
38
|
+
let(:income) { 100000000 }
|
39
|
+
its(:rate) { should be == Rational(161, 335) }
|
40
|
+
its(:gross_income) { should be == 100000000 }
|
41
|
+
its(:net_income) { should be == 51940200 }
|
42
|
+
its(:taxes) { should be == 48059800 }
|
43
|
+
end
|
44
|
+
|
45
|
+
describe "from net income of 0" do
|
46
|
+
let(:type) { :net }
|
47
|
+
let(:income) { 0 }
|
48
|
+
its(:rate) { should be == Rational(0, 1) }
|
49
|
+
its(:gross_income) { should be == 0 }
|
50
|
+
its(:net_income) { should be == 0 }
|
51
|
+
its(:taxes) { should be == 0 }
|
52
|
+
end
|
53
|
+
|
54
|
+
describe "from net income of 1000" do
|
55
|
+
let(:type) { :net }
|
56
|
+
let(:income) { 1000 }
|
57
|
+
its(:rate) { should be == Rational(0, 1) }
|
58
|
+
its(:gross_income) { should be == 1000 }
|
59
|
+
its(:net_income) { should be == 1000 }
|
60
|
+
its(:taxes) { should be == 0 }
|
61
|
+
end
|
62
|
+
|
63
|
+
describe "from net income of 10000" do
|
64
|
+
let(:type) { :net }
|
65
|
+
let(:income) { 10000 }
|
66
|
+
its(:rate) { should be == Rational(0, 1) }
|
67
|
+
its(:gross_income) { should be == 10000 }
|
68
|
+
its(:net_income) { should be == 10000 }
|
69
|
+
its(:taxes) { should be == 0 }
|
70
|
+
end
|
71
|
+
|
72
|
+
describe "from net income of 100000" do
|
73
|
+
let(:type) { :net }
|
74
|
+
let(:income) { 100000 }
|
75
|
+
its(:rate) { should be == Rational(0, 1) }
|
76
|
+
its(:gross_income) { should be == 100000 }
|
77
|
+
its(:net_income) { should be == 100000 }
|
78
|
+
its(:taxes) { should be == 0 }
|
79
|
+
end
|
80
|
+
|
81
|
+
describe "from net income of 100000000" do
|
82
|
+
let(:type) { :net }
|
83
|
+
let(:income) { 100000000 }
|
84
|
+
its(:rate) { should be == Rational(99, 202) }
|
85
|
+
its(:gross_income) { should be == 196119600 }
|
86
|
+
its(:net_income) { should be == 100000000 }
|
87
|
+
its(:taxes) { should be == 96119600 }
|
88
|
+
end
|
89
|
+
end
|
@@ -0,0 +1,89 @@
|
|
1
|
+
describe IncomeTax::Countries::Serbia do
|
2
|
+
subject(:result) { described_class.new(income: income, income_type: type) }
|
3
|
+
let(:type) { :gross }
|
4
|
+
|
5
|
+
describe "from gross income of 0" do
|
6
|
+
let(:income) { 0 }
|
7
|
+
its(:rate) { should be == Rational(0, 1) }
|
8
|
+
its(:gross_income) { should be == 0 }
|
9
|
+
its(:net_income) { should be == 0 }
|
10
|
+
its(:taxes) { should be == 0 }
|
11
|
+
end
|
12
|
+
|
13
|
+
describe "from gross income of 1000" do
|
14
|
+
let(:income) { 1000 }
|
15
|
+
its(:rate) { should be == Rational(1, 10) }
|
16
|
+
its(:gross_income) { should be == 1000 }
|
17
|
+
its(:net_income) { should be == 900 }
|
18
|
+
its(:taxes) { should be == 100 }
|
19
|
+
end
|
20
|
+
|
21
|
+
describe "from gross income of 10000" do
|
22
|
+
let(:income) { 10000 }
|
23
|
+
its(:rate) { should be == Rational(1, 10) }
|
24
|
+
its(:gross_income) { should be == 10000 }
|
25
|
+
its(:net_income) { should be == 9000 }
|
26
|
+
its(:taxes) { should be == 1000 }
|
27
|
+
end
|
28
|
+
|
29
|
+
describe "from gross income of 100000" do
|
30
|
+
let(:income) { 100000 }
|
31
|
+
its(:rate) { should be == Rational(1, 10) }
|
32
|
+
its(:gross_income) { should be == 100000 }
|
33
|
+
its(:net_income) { should be == 90000 }
|
34
|
+
its(:taxes) { should be == 10000 }
|
35
|
+
end
|
36
|
+
|
37
|
+
describe "from gross income of 100000000" do
|
38
|
+
let(:income) { 100000000 }
|
39
|
+
its(:rate) { should be == Rational(29, 83) }
|
40
|
+
its(:gross_income) { should be == 100000000 }
|
41
|
+
its(:net_income) { should be == 65059964 }
|
42
|
+
its(:taxes) { should be == 34940036 }
|
43
|
+
end
|
44
|
+
|
45
|
+
describe "from net income of 0" do
|
46
|
+
let(:type) { :net }
|
47
|
+
let(:income) { 0 }
|
48
|
+
its(:rate) { should be == Rational(0, 1) }
|
49
|
+
its(:gross_income) { should be == 0 }
|
50
|
+
its(:net_income) { should be == 0 }
|
51
|
+
its(:taxes) { should be == 0 }
|
52
|
+
end
|
53
|
+
|
54
|
+
describe "from net income of 1000" do
|
55
|
+
let(:type) { :net }
|
56
|
+
let(:income) { 1000 }
|
57
|
+
its(:rate) { should be == Rational(1, 10) }
|
58
|
+
its(:gross_income) { should be == "1111.1111111111111".to_d }
|
59
|
+
its(:net_income) { should be == 1000 }
|
60
|
+
its(:taxes) { should be == "111.111111111111111".to_d }
|
61
|
+
end
|
62
|
+
|
63
|
+
describe "from net income of 10000" do
|
64
|
+
let(:type) { :net }
|
65
|
+
let(:income) { 10000 }
|
66
|
+
its(:rate) { should be == Rational(1, 10) }
|
67
|
+
its(:gross_income) { should be == "11111.1111111111111".to_d }
|
68
|
+
its(:net_income) { should be == 10000 }
|
69
|
+
its(:taxes) { should be == "1111.1111111111111".to_d }
|
70
|
+
end
|
71
|
+
|
72
|
+
describe "from net income of 100000" do
|
73
|
+
let(:type) { :net }
|
74
|
+
let(:income) { 100000 }
|
75
|
+
its(:rate) { should be == Rational(1, 10) }
|
76
|
+
its(:gross_income) { should be == "111111.111111111111".to_d }
|
77
|
+
its(:net_income) { should be == 100000 }
|
78
|
+
its(:taxes) { should be == "11111.1111111111111".to_d }
|
79
|
+
end
|
80
|
+
|
81
|
+
describe "from net income of 100000000" do
|
82
|
+
let(:type) { :net }
|
83
|
+
let(:income) { 100000000 }
|
84
|
+
its(:rate) { should be == Rational(136, 389) }
|
85
|
+
its(:gross_income) { should be == "153753901.538461538".to_d }
|
86
|
+
its(:net_income) { should be == 100000000 }
|
87
|
+
its(:taxes) { should be == "53753901.5384615385".to_d }
|
88
|
+
end
|
89
|
+
end
|
@@ -0,0 +1,89 @@
|
|
1
|
+
describe IncomeTax::Countries::Seychelles do
|
2
|
+
subject(:result) { described_class.new(income: income, income_type: type) }
|
3
|
+
let(:type) { :gross }
|
4
|
+
|
5
|
+
describe "from gross income of 0" do
|
6
|
+
let(:income) { 0 }
|
7
|
+
its(:rate) { should be == Rational(3, 20) }
|
8
|
+
its(:gross_income) { should be == 0 }
|
9
|
+
its(:net_income) { should be == 0 }
|
10
|
+
its(:taxes) { should be == 0 }
|
11
|
+
end
|
12
|
+
|
13
|
+
describe "from gross income of 1000" do
|
14
|
+
let(:income) { 1000 }
|
15
|
+
its(:rate) { should be == Rational(3, 20) }
|
16
|
+
its(:gross_income) { should be == 1000 }
|
17
|
+
its(:net_income) { should be == 850 }
|
18
|
+
its(:taxes) { should be == 150 }
|
19
|
+
end
|
20
|
+
|
21
|
+
describe "from gross income of 10000" do
|
22
|
+
let(:income) { 10000 }
|
23
|
+
its(:rate) { should be == Rational(3, 20) }
|
24
|
+
its(:gross_income) { should be == 10000 }
|
25
|
+
its(:net_income) { should be == 8500 }
|
26
|
+
its(:taxes) { should be == 1500 }
|
27
|
+
end
|
28
|
+
|
29
|
+
describe "from gross income of 100000" do
|
30
|
+
let(:income) { 100000 }
|
31
|
+
its(:rate) { should be == Rational(3, 20) }
|
32
|
+
its(:gross_income) { should be == 100000 }
|
33
|
+
its(:net_income) { should be == 85000 }
|
34
|
+
its(:taxes) { should be == 15000 }
|
35
|
+
end
|
36
|
+
|
37
|
+
describe "from gross income of 100000000" do
|
38
|
+
let(:income) { 100000000 }
|
39
|
+
its(:rate) { should be == Rational(3, 20) }
|
40
|
+
its(:gross_income) { should be == 100000000 }
|
41
|
+
its(:net_income) { should be == 85000000 }
|
42
|
+
its(:taxes) { should be == 15000000 }
|
43
|
+
end
|
44
|
+
|
45
|
+
describe "from net income of 0" do
|
46
|
+
let(:type) { :net }
|
47
|
+
let(:income) { 0 }
|
48
|
+
its(:rate) { should be == Rational(3, 20) }
|
49
|
+
its(:gross_income) { should be == 0 }
|
50
|
+
its(:net_income) { should be == 0 }
|
51
|
+
its(:taxes) { should be == 0 }
|
52
|
+
end
|
53
|
+
|
54
|
+
describe "from net income of 1000" do
|
55
|
+
let(:type) { :net }
|
56
|
+
let(:income) { 1000 }
|
57
|
+
its(:rate) { should be == Rational(3, 20) }
|
58
|
+
its(:gross_income) { should be == "1176.47058823529412".to_d }
|
59
|
+
its(:net_income) { should be == 1000 }
|
60
|
+
its(:taxes) { should be == "176.470588235294118".to_d }
|
61
|
+
end
|
62
|
+
|
63
|
+
describe "from net income of 10000" do
|
64
|
+
let(:type) { :net }
|
65
|
+
let(:income) { 10000 }
|
66
|
+
its(:rate) { should be == Rational(3, 20) }
|
67
|
+
its(:gross_income) { should be == "11764.705882352941".to_d }
|
68
|
+
its(:net_income) { should be == 10000 }
|
69
|
+
its(:taxes) { should be == "1764.70588235294118".to_d }
|
70
|
+
end
|
71
|
+
|
72
|
+
describe "from net income of 100000" do
|
73
|
+
let(:type) { :net }
|
74
|
+
let(:income) { 100000 }
|
75
|
+
its(:rate) { should be == Rational(3, 20) }
|
76
|
+
its(:gross_income) { should be == "117647.058823529412".to_d }
|
77
|
+
its(:net_income) { should be == 100000 }
|
78
|
+
its(:taxes) { should be == "17647.0588235294118".to_d }
|
79
|
+
end
|
80
|
+
|
81
|
+
describe "from net income of 100000000" do
|
82
|
+
let(:type) { :net }
|
83
|
+
let(:income) { 100000000 }
|
84
|
+
its(:rate) { should be == Rational(3, 20) }
|
85
|
+
its(:gross_income) { should be == "117647058.82352941".to_d }
|
86
|
+
its(:net_income) { should be == 100000000 }
|
87
|
+
its(:taxes) { should be == "17647058.823529412".to_d }
|
88
|
+
end
|
89
|
+
end
|
@@ -0,0 +1,89 @@
|
|
1
|
+
describe IncomeTax::Countries::SierraLeone do
|
2
|
+
subject(:result) { described_class.new(income: income, income_type: type) }
|
3
|
+
let(:type) { :gross }
|
4
|
+
|
5
|
+
describe "from gross income of 0" do
|
6
|
+
let(:income) { 0 }
|
7
|
+
its(:rate) { should be == Rational(0, 1) }
|
8
|
+
its(:gross_income) { should be == 0 }
|
9
|
+
its(:net_income) { should be == 0 }
|
10
|
+
its(:taxes) { should be == 0 }
|
11
|
+
end
|
12
|
+
|
13
|
+
describe "from gross income of 1000" do
|
14
|
+
let(:income) { 1000 }
|
15
|
+
its(:rate) { should be == Rational(0, 1) }
|
16
|
+
its(:gross_income) { should be == 1000 }
|
17
|
+
its(:net_income) { should be == 1000 }
|
18
|
+
its(:taxes) { should be == 0 }
|
19
|
+
end
|
20
|
+
|
21
|
+
describe "from gross income of 10000" do
|
22
|
+
let(:income) { 10000 }
|
23
|
+
its(:rate) { should be == Rational(0, 1) }
|
24
|
+
its(:gross_income) { should be == 10000 }
|
25
|
+
its(:net_income) { should be == 10000 }
|
26
|
+
its(:taxes) { should be == 0 }
|
27
|
+
end
|
28
|
+
|
29
|
+
describe "from gross income of 100000" do
|
30
|
+
let(:income) { 100000 }
|
31
|
+
its(:rate) { should be == Rational(0, 1) }
|
32
|
+
its(:gross_income) { should be == 100000 }
|
33
|
+
its(:net_income) { should be == 100000 }
|
34
|
+
its(:taxes) { should be == 0 }
|
35
|
+
end
|
36
|
+
|
37
|
+
describe "from gross income of 100000000" do
|
38
|
+
let(:income) { 100000000 }
|
39
|
+
its(:rate) { should be == Rational(329, 1152) }
|
40
|
+
its(:gross_income) { should be == 100000000 }
|
41
|
+
its(:net_income) { should be == 71440000 }
|
42
|
+
its(:taxes) { should be == 28560000 }
|
43
|
+
end
|
44
|
+
|
45
|
+
describe "from net income of 0" do
|
46
|
+
let(:type) { :net }
|
47
|
+
let(:income) { 0 }
|
48
|
+
its(:rate) { should be == Rational(0, 1) }
|
49
|
+
its(:gross_income) { should be == 0 }
|
50
|
+
its(:net_income) { should be == 0 }
|
51
|
+
its(:taxes) { should be == 0 }
|
52
|
+
end
|
53
|
+
|
54
|
+
describe "from net income of 1000" do
|
55
|
+
let(:type) { :net }
|
56
|
+
let(:income) { 1000 }
|
57
|
+
its(:rate) { should be == Rational(0, 1) }
|
58
|
+
its(:gross_income) { should be == 1000 }
|
59
|
+
its(:net_income) { should be == 1000 }
|
60
|
+
its(:taxes) { should be == 0 }
|
61
|
+
end
|
62
|
+
|
63
|
+
describe "from net income of 10000" do
|
64
|
+
let(:type) { :net }
|
65
|
+
let(:income) { 10000 }
|
66
|
+
its(:rate) { should be == Rational(0, 1) }
|
67
|
+
its(:gross_income) { should be == 10000 }
|
68
|
+
its(:net_income) { should be == 10000 }
|
69
|
+
its(:taxes) { should be == 0 }
|
70
|
+
end
|
71
|
+
|
72
|
+
describe "from net income of 100000" do
|
73
|
+
let(:type) { :net }
|
74
|
+
let(:income) { 100000 }
|
75
|
+
its(:rate) { should be == Rational(0, 1) }
|
76
|
+
its(:gross_income) { should be == 100000 }
|
77
|
+
its(:net_income) { should be == 100000 }
|
78
|
+
its(:taxes) { should be == 0 }
|
79
|
+
end
|
80
|
+
|
81
|
+
describe "from net income of 100000000" do
|
82
|
+
let(:type) { :net }
|
83
|
+
let(:income) { 100000000 }
|
84
|
+
its(:rate) { should be == Rational(51, 176) }
|
85
|
+
its(:gross_income) { should be == 140800000 }
|
86
|
+
its(:net_income) { should be == 100000000 }
|
87
|
+
its(:taxes) { should be == 40800000 }
|
88
|
+
end
|
89
|
+
end
|
@@ -0,0 +1,89 @@
|
|
1
|
+
describe IncomeTax::Countries::Singapore do
|
2
|
+
subject(:result) { described_class.new(income: income, income_type: type) }
|
3
|
+
let(:type) { :gross }
|
4
|
+
|
5
|
+
describe "from gross income of 0" do
|
6
|
+
let(:income) { 0 }
|
7
|
+
its(:rate) { should be == Rational(0, 1) }
|
8
|
+
its(:gross_income) { should be == 0 }
|
9
|
+
its(:net_income) { should be == 0 }
|
10
|
+
its(:taxes) { should be == 0 }
|
11
|
+
end
|
12
|
+
|
13
|
+
describe "from gross income of 1000" do
|
14
|
+
let(:income) { 1000 }
|
15
|
+
its(:rate) { should be == Rational(0, 1) }
|
16
|
+
its(:gross_income) { should be == 1000 }
|
17
|
+
its(:net_income) { should be == 1000 }
|
18
|
+
its(:taxes) { should be == 0 }
|
19
|
+
end
|
20
|
+
|
21
|
+
describe "from gross income of 10000" do
|
22
|
+
let(:income) { 10000 }
|
23
|
+
its(:rate) { should be == Rational(0, 1) }
|
24
|
+
its(:gross_income) { should be == 10000 }
|
25
|
+
its(:net_income) { should be == 10000 }
|
26
|
+
its(:taxes) { should be == 0 }
|
27
|
+
end
|
28
|
+
|
29
|
+
describe "from gross income of 100000" do
|
30
|
+
let(:income) { 100000 }
|
31
|
+
its(:rate) { should be == Rational(10, 177) }
|
32
|
+
its(:gross_income) { should be == 100000 }
|
33
|
+
its(:net_income) { should be == 94350 }
|
34
|
+
its(:taxes) { should be == 5650 }
|
35
|
+
end
|
36
|
+
|
37
|
+
describe "from gross income of 100000000" do
|
38
|
+
let(:income) { 100000000 }
|
39
|
+
its(:rate) { should be == Rational(177, 886) }
|
40
|
+
its(:gross_income) { should be == 100000000 }
|
41
|
+
its(:net_income) { should be == 80021650 }
|
42
|
+
its(:taxes) { should be == 19978350 }
|
43
|
+
end
|
44
|
+
|
45
|
+
describe "from net income of 0" do
|
46
|
+
let(:type) { :net }
|
47
|
+
let(:income) { 0 }
|
48
|
+
its(:rate) { should be == Rational(0, 1) }
|
49
|
+
its(:gross_income) { should be == 0 }
|
50
|
+
its(:net_income) { should be == 0 }
|
51
|
+
its(:taxes) { should be == 0 }
|
52
|
+
end
|
53
|
+
|
54
|
+
describe "from net income of 1000" do
|
55
|
+
let(:type) { :net }
|
56
|
+
let(:income) { 1000 }
|
57
|
+
its(:rate) { should be == Rational(0, 1) }
|
58
|
+
its(:gross_income) { should be == 1000 }
|
59
|
+
its(:net_income) { should be == 1000 }
|
60
|
+
its(:taxes) { should be == 0 }
|
61
|
+
end
|
62
|
+
|
63
|
+
describe "from net income of 10000" do
|
64
|
+
let(:type) { :net }
|
65
|
+
let(:income) { 10000 }
|
66
|
+
its(:rate) { should be == Rational(0, 1) }
|
67
|
+
its(:gross_income) { should be == 10000 }
|
68
|
+
its(:net_income) { should be == 10000 }
|
69
|
+
its(:taxes) { should be == 0 }
|
70
|
+
end
|
71
|
+
|
72
|
+
describe "from net income of 100000" do
|
73
|
+
let(:type) { :net }
|
74
|
+
let(:income) { 100000 }
|
75
|
+
its(:rate) { should be == Rational(59, 983) }
|
76
|
+
its(:gross_income) { should be == "106384.180790960452".to_d }
|
77
|
+
its(:net_income) { should be == 100000 }
|
78
|
+
its(:taxes) { should be == "6384.180790960452".to_d }
|
79
|
+
end
|
80
|
+
|
81
|
+
describe "from net income of 100000000" do
|
82
|
+
let(:type) { :net }
|
83
|
+
let(:income) { 100000000 }
|
84
|
+
its(:rate) { should be == Rational(219, 1096) }
|
85
|
+
its(:gross_income) { should be == "124972937.5".to_d }
|
86
|
+
its(:net_income) { should be == 100000000 }
|
87
|
+
its(:taxes) { should be == "24972937.5".to_d }
|
88
|
+
end
|
89
|
+
end
|
@@ -0,0 +1,89 @@
|
|
1
|
+
describe IncomeTax::Countries::SintMaarten do
|
2
|
+
subject(:result) { described_class.new(income: income, income_type: type) }
|
3
|
+
let(:type) { :gross }
|
4
|
+
|
5
|
+
describe "from gross income of 0" do
|
6
|
+
let(:income) { 0 }
|
7
|
+
its(:rate) { should be == Rational(0, 1) }
|
8
|
+
its(:gross_income) { should be == 0 }
|
9
|
+
its(:net_income) { should be == 0 }
|
10
|
+
its(:taxes) { should be == 0 }
|
11
|
+
end
|
12
|
+
|
13
|
+
describe "from gross income of 1000" do
|
14
|
+
let(:income) { 1000 }
|
15
|
+
its(:rate) { should be == Rational(1, 8) }
|
16
|
+
its(:gross_income) { should be == 1000 }
|
17
|
+
its(:net_income) { should be == 875 }
|
18
|
+
its(:taxes) { should be == 125 }
|
19
|
+
end
|
20
|
+
|
21
|
+
describe "from gross income of 10000" do
|
22
|
+
let(:income) { 10000 }
|
23
|
+
its(:rate) { should be == Rational(1, 8) }
|
24
|
+
its(:gross_income) { should be == 10000 }
|
25
|
+
its(:net_income) { should be == 8750 }
|
26
|
+
its(:taxes) { should be == 1250 }
|
27
|
+
end
|
28
|
+
|
29
|
+
describe "from gross income of 100000" do
|
30
|
+
let(:income) { 100000 }
|
31
|
+
its(:rate) { should be == Rational(5, 21) }
|
32
|
+
its(:gross_income) { should be == 100000 }
|
33
|
+
its(:net_income) { should be == "76190.5625".to_d }
|
34
|
+
its(:taxes) { should be == "23809.4375".to_d }
|
35
|
+
end
|
36
|
+
|
37
|
+
describe "from gross income of 100000000" do
|
38
|
+
let(:income) { 100000000 }
|
39
|
+
its(:rate) { should be == Rational(216, 455) }
|
40
|
+
its(:gross_income) { should be == 100000000 }
|
41
|
+
its(:net_income) { should be == "52526497.8875".to_d }
|
42
|
+
its(:taxes) { should be == "47473502.1125".to_d }
|
43
|
+
end
|
44
|
+
|
45
|
+
describe "from net income of 0" do
|
46
|
+
let(:type) { :net }
|
47
|
+
let(:income) { 0 }
|
48
|
+
its(:rate) { should be == Rational(0, 1) }
|
49
|
+
its(:gross_income) { should be == 0 }
|
50
|
+
its(:net_income) { should be == 0 }
|
51
|
+
its(:taxes) { should be == 0 }
|
52
|
+
end
|
53
|
+
|
54
|
+
describe "from net income of 1000" do
|
55
|
+
let(:type) { :net }
|
56
|
+
let(:income) { 1000 }
|
57
|
+
its(:rate) { should be == Rational(1, 8) }
|
58
|
+
its(:gross_income) { should be == "1142.8571428571429".to_d }
|
59
|
+
its(:net_income) { should be == 1000 }
|
60
|
+
its(:taxes) { should be == "142.857142857142857".to_d }
|
61
|
+
end
|
62
|
+
|
63
|
+
describe "from net income of 10000" do
|
64
|
+
let(:type) { :net }
|
65
|
+
let(:income) { 10000 }
|
66
|
+
its(:rate) { should be == Rational(1, 8) }
|
67
|
+
its(:gross_income) { should be == "11428.571428571429".to_d }
|
68
|
+
its(:net_income) { should be == 10000 }
|
69
|
+
its(:taxes) { should be == "1428.57142857142857".to_d }
|
70
|
+
end
|
71
|
+
|
72
|
+
describe "from net income of 100000" do
|
73
|
+
let(:type) { :net }
|
74
|
+
let(:income) { 100000 }
|
75
|
+
its(:rate) { should be == Rational(1339, 4686) }
|
76
|
+
its(:gross_income) { should be == "140004.02380952381".to_d }
|
77
|
+
its(:net_income) { should be == 100000 }
|
78
|
+
its(:taxes) { should be == "40004.02380952381".to_d }
|
79
|
+
end
|
80
|
+
|
81
|
+
describe "from net income of 100000000" do
|
82
|
+
let(:type) { :net }
|
83
|
+
let(:income) { 100000000 }
|
84
|
+
its(:rate) { should be == Rational(85, 179) }
|
85
|
+
its(:gross_income) { should be == "190425718.309523809".to_d }
|
86
|
+
its(:net_income) { should be == 100000000 }
|
87
|
+
its(:taxes) { should be == "90425718.30952381".to_d }
|
88
|
+
end
|
89
|
+
end
|
@@ -0,0 +1,89 @@
|
|
1
|
+
describe IncomeTax::Countries::Slovakia do
|
2
|
+
subject(:result) { described_class.new(income: income, income_type: type) }
|
3
|
+
let(:type) { :gross }
|
4
|
+
|
5
|
+
describe "from gross income of 0" do
|
6
|
+
let(:income) { 0 }
|
7
|
+
its(:rate) { should be == Rational(0, 1) }
|
8
|
+
its(:gross_income) { should be == 0 }
|
9
|
+
its(:net_income) { should be == 0 }
|
10
|
+
its(:taxes) { should be == 0 }
|
11
|
+
end
|
12
|
+
|
13
|
+
describe "from gross income of 1000" do
|
14
|
+
let(:income) { 1000 }
|
15
|
+
its(:rate) { should be == Rational(19, 100) }
|
16
|
+
its(:gross_income) { should be == 1000 }
|
17
|
+
its(:net_income) { should be == 810 }
|
18
|
+
its(:taxes) { should be == 190 }
|
19
|
+
end
|
20
|
+
|
21
|
+
describe "from gross income of 10000" do
|
22
|
+
let(:income) { 10000 }
|
23
|
+
its(:rate) { should be == Rational(19, 100) }
|
24
|
+
its(:gross_income) { should be == 10000 }
|
25
|
+
its(:net_income) { should be == 8100 }
|
26
|
+
its(:taxes) { should be == 1900 }
|
27
|
+
end
|
28
|
+
|
29
|
+
describe "from gross income of 100000" do
|
30
|
+
let(:income) { 100000 }
|
31
|
+
its(:rate) { should be == Rational(25, 109) }
|
32
|
+
its(:gross_income) { should be == 100000 }
|
33
|
+
its(:net_income) { should be == "77064.06".to_d }
|
34
|
+
its(:taxes) { should be == "22935.94".to_d }
|
35
|
+
end
|
36
|
+
|
37
|
+
describe "from gross income of 100000000" do
|
38
|
+
let(:income) { 100000000 }
|
39
|
+
its(:rate) { should be == Rational(2040, 8161) }
|
40
|
+
its(:gross_income) { should be == 100000000 }
|
41
|
+
its(:net_income) { should be == "75002064.06".to_d }
|
42
|
+
its(:taxes) { should be == "24997935.94".to_d }
|
43
|
+
end
|
44
|
+
|
45
|
+
describe "from net income of 0" do
|
46
|
+
let(:type) { :net }
|
47
|
+
let(:income) { 0 }
|
48
|
+
its(:rate) { should be == Rational(0, 1) }
|
49
|
+
its(:gross_income) { should be == 0 }
|
50
|
+
its(:net_income) { should be == 0 }
|
51
|
+
its(:taxes) { should be == 0 }
|
52
|
+
end
|
53
|
+
|
54
|
+
describe "from net income of 1000" do
|
55
|
+
let(:type) { :net }
|
56
|
+
let(:income) { 1000 }
|
57
|
+
its(:rate) { should be == Rational(19, 100) }
|
58
|
+
its(:gross_income) { should be == "1234.5679012345679".to_d }
|
59
|
+
its(:net_income) { should be == 1000 }
|
60
|
+
its(:taxes) { should be == "234.5679012345679".to_d }
|
61
|
+
end
|
62
|
+
|
63
|
+
describe "from net income of 10000" do
|
64
|
+
let(:type) { :net }
|
65
|
+
let(:income) { 10000 }
|
66
|
+
its(:rate) { should be == Rational(19, 100) }
|
67
|
+
its(:gross_income) { should be == "12345.679012345679".to_d }
|
68
|
+
its(:net_income) { should be == 10000 }
|
69
|
+
its(:taxes) { should be == "2345.679012345679".to_d }
|
70
|
+
end
|
71
|
+
|
72
|
+
describe "from net income of 100000" do
|
73
|
+
let(:type) { :net }
|
74
|
+
let(:income) { 100000 }
|
75
|
+
its(:rate) { should be == Rational(63, 269) }
|
76
|
+
its(:gross_income) { should be == "130581.253333333333".to_d }
|
77
|
+
its(:net_income) { should be == 100000 }
|
78
|
+
its(:taxes) { should be == "30581.2533333333333".to_d }
|
79
|
+
end
|
80
|
+
|
81
|
+
describe "from net income of 100000000" do
|
82
|
+
let(:type) { :net }
|
83
|
+
let(:income) { 100000000 }
|
84
|
+
its(:rate) { should be == Rational(2453, 9813) }
|
85
|
+
its(:gross_income) { should be == "133330581.253333333".to_d }
|
86
|
+
its(:net_income) { should be == 100000000 }
|
87
|
+
its(:taxes) { should be == "33330581.253333333".to_d }
|
88
|
+
end
|
89
|
+
end
|