xirr 0.2.8 → 0.2.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: dcb7b25e26618e39ecb5c1e8b38ad211be4edc73
4
- data.tar.gz: 0c845e053436159125d5b8bedf2dd08e8243cdbc
3
+ metadata.gz: 1f0f71683833379725ed955370cc85fd6c40c7f0
4
+ data.tar.gz: 9052d4a3b8bc5cc70c031c4c9f09f5b82ec808db
5
5
  SHA512:
6
- metadata.gz: ec7a9821be4721669be0d656864b1d7db88f5d0fc1ec4306b0f190d5b2d2143f0b98ebe338589f3de60af6f07f9077a9a19b9022ee3d64f0aeec81f94b1885b7
7
- data.tar.gz: dcf0c3570dbc34e6595cfd3f0e1976ec4f2bd876e1a9ad11dfebdc52b75494199a55f3b4dabb12185b07d36abe79c1a987453a2ebe3889fd4bc756bc00bc2253
6
+ metadata.gz: 77d29b67ba5b337ee25d8170b4e8942568543b5d026dfbabf0bc250297f2ff82e0aef093ce8b1b00b1d16f774cfa672c0cd4e04e71007807e9a86632259667ff
7
+ data.tar.gz: cc54b04a7d005c2045594e99f1bd75550250c4d1c10bb6ed40a279f08ec3c83c99fd9f189ba500d216ff79ad66ae0a495de80b7e016ecef345aefe8e668b484c
data/CHANGE_LOG.md CHANGED
@@ -1,3 +1,7 @@
1
+ ## Version 0.2.9
2
+
3
+ * Cashflow validation excludes zeros
4
+
1
5
  ## Version 0.2.8
2
6
 
3
7
  * Added missing tests
@@ -40,7 +40,6 @@ module Xirr
40
40
 
41
41
  private
42
42
 
43
- # @param right [BigDecimal]
44
43
  # @param midpoint [BigDecimal]
45
44
  # @return [Boolean]
46
45
  # Checks if result is the right limit.
data/lib/xirr/cashflow.rb CHANGED
@@ -152,10 +152,9 @@ module Xirr
152
152
  # @see #negatives
153
153
  # Uses partition to separate the investment transactions Negatives and the income transactions (Positives)
154
154
  def split_transactions
155
- @negatives, @positives = self.partition { |x| x.amount >= 0 } # Inverted as negative amount is good
155
+ @negatives, @positives = self.partition { |x| x.amount > 0 } # Inverted as negative amount is good
156
156
  end
157
157
 
158
-
159
158
  end
160
159
 
161
160
  end
data/lib/xirr/version.rb CHANGED
@@ -1,4 +1,4 @@
1
1
  module Xirr
2
2
  # Version of the Gem
3
- VERSION = "0.2.8"
3
+ VERSION = "0.2.9"
4
4
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: xirr
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.8
4
+ version: 0.2.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - tubedude
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-08-11 00:00:00.000000000 Z
11
+ date: 2014-08-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler