income-tax 0.3.0 → 0.3.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/income_tax/countries/iceland.rb +1 -1
- data/lib/income_tax/version.rb +1 -1
- data/readme.md +2 -2
- data/spec/income_tax/countries/iceland_spec.rb +6 -6
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5eff04c9bad9eb3a9181cae31fa8e90a058a62b5
|
4
|
+
data.tar.gz: 5629b5a76ffb589ad3e8e130266b4825a6212ac3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f516c8121d16ad66fdd4414ad470d04a839cfa1fa643a5c25b1cf221362e35d8df35fab60fe4f60c09f39cf582fb19f1571825a7cd8681d2c82389b25de5f936
|
7
|
+
data.tar.gz: 26223c389b23bdacc52bdc41b46b63fbdc0fed4b6f93a02255eecf500d7c5ca572250f76b9e839bbde09425386ca25095855b04dd07620efea4a9c18d34e3ce1
|
data/lib/income_tax/version.rb
CHANGED
data/readme.md
CHANGED
@@ -69,7 +69,7 @@ There is also a [full list of countries](locations.md).
|
|
69
69
|
#### United States
|
70
70
|
|
71
71
|
* **Federal only:** By default, only federal taxes are calculated.
|
72
|
-
* **State taxes:** Passing in the `state` option with either the full name of the state
|
72
|
+
* **State taxes:** Passing in the `state` option with either the full name of the state or the two letter abbreviation will also take state taxes into account.
|
73
73
|
* **Washington, D.C.:** Use the state option as if it was a state, which by the way it should be.
|
74
74
|
* **Guam, Puerto Rico, and other territories:** Treat them like separate countries.
|
75
75
|
|
@@ -83,7 +83,7 @@ IncomeTax.new("Guam", "100k")
|
|
83
83
|
#### Canada
|
84
84
|
|
85
85
|
* **Federal only:** By default, only federal taxes are calculated.
|
86
|
-
* **Territorial taxes:** Passing in the `territory` option with either the full name of the
|
86
|
+
* **Territorial taxes:** Passing in the `territory` option with either the full name of the territory or the two letter abbreviation will also take territorial taxes into account.
|
87
87
|
|
88
88
|
``` ruby
|
89
89
|
IncomeTax.new("CA", "100k")
|
@@ -41,10 +41,10 @@ describe IncomeTax::Countries::Iceland do
|
|
41
41
|
describe "from gross income of 100000000" do
|
42
42
|
let(:tax_year) { 2015 }
|
43
43
|
let(:income) { 100000000 }
|
44
|
-
its(:rate) { should be == Rational(
|
44
|
+
its(:rate) { should be == Rational(145, 314) }
|
45
45
|
its(:gross_income) { should be == 100000000 }
|
46
|
-
its(:net_income) { should be == "
|
47
|
-
its(:taxes) { should be == "
|
46
|
+
its(:net_income) { should be == "53821909.276".to_d }
|
47
|
+
its(:taxes) { should be == "46178090.724".to_d }
|
48
48
|
end
|
49
49
|
|
50
50
|
describe "from net income of 0" do
|
@@ -91,9 +91,9 @@ describe IncomeTax::Countries::Iceland do
|
|
91
91
|
let(:type) { :net }
|
92
92
|
let(:tax_year) { 2015 }
|
93
93
|
let(:income) { 100000000 }
|
94
|
-
its(:rate) { should be == Rational(
|
95
|
-
its(:gross_income) { should be == "
|
94
|
+
its(:rate) { should be == Rational(67, 145) }
|
95
|
+
its(:gross_income) { should be == "185896746.138392857".to_d }
|
96
96
|
its(:net_income) { should be == 100000000 }
|
97
|
-
its(:taxes) { should be == "
|
97
|
+
its(:taxes) { should be == "85896746.138392857".to_d }
|
98
98
|
end
|
99
99
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: income-tax
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Konstantin Haase
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-02-
|
11
|
+
date: 2016-02-11 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: Estimate Income Tax for different Countries
|
14
14
|
email: income-tax-gem@rkh.im
|
@@ -766,7 +766,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
766
766
|
version: '0'
|
767
767
|
requirements: []
|
768
768
|
rubyforge_project:
|
769
|
-
rubygems_version: 2.
|
769
|
+
rubygems_version: 2.5.1
|
770
770
|
signing_key:
|
771
771
|
specification_version: 4
|
772
772
|
summary: Given a country and a gross or net income, estimate personal income tax.
|