borel 0.3.1 → 0.3.2

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.
@@ -4,3 +4,5 @@ require 'borel/array'
4
4
  require 'borel/range'
5
5
  require 'borel/numeric'
6
6
  require 'borel/nil_class'
7
+
8
+ require 'borel/version'
@@ -12,11 +12,11 @@ class Interval::Multiple < Interval
12
12
  end
13
13
 
14
14
  def inf
15
- first.inf
15
+ components.first.inf
16
16
  end
17
17
 
18
18
  def sup
19
- last.sup
19
+ components.last.sup
20
20
  end
21
21
 
22
22
  def construction
@@ -1,7 +1,7 @@
1
1
  module Borel
2
2
  MAJOR = 0
3
3
  MINOR = 3
4
- TINY = 1
4
+ TINY = 2
5
5
 
6
6
  VERSION = [MAJOR, MINOR, TINY].join('.')
7
7
 
@@ -0,0 +1,15 @@
1
+ require 'borel/interval'
2
+
3
+ describe Interval::Multiple do
4
+ context "#inf" do
5
+ specify "[[-1,2],[3]] -> -1" do
6
+ Interval[[-1,2],[3]].inf.should be -1
7
+ end
8
+ end
9
+
10
+ context "#sup" do
11
+ specify "[[-1,2],[3]] -> 3" do
12
+ Interval[[-1,2],[3]].sup.should be 3
13
+ end
14
+ end
15
+ end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: borel
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.1
4
+ version: 0.3.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -44,6 +44,7 @@ files:
44
44
  - lib/borel/range.rb
45
45
  - lib/borel/version.rb
46
46
  - spec/array_spec.rb
47
+ - spec/interval_multiple_spec.rb
47
48
  - spec/interval_spec.rb
48
49
  - spec/math_extensions/interval_arithmetic_spec.rb
49
50
  - spec/math_extensions/randomizable_spec.rb