proj4rb 0.4.0-x86-mingw32 → 0.4.1-x86-mingw32

Sign up to get free protection for your applications and to get access to all the features.
data/test/test_units.rb CHANGED
@@ -1,45 +1,46 @@
1
- $: << 'lib' << 'ext'
1
+ # encoding: UTF-8
2
+
2
3
  require File.join(File.dirname(__FILE__), '..', 'lib', 'proj4')
3
4
  require 'test/unit'
4
5
 
5
6
  if Proj4::LIBVERSION >= 449
6
- class UnitsTest < Test::Unit::TestCase
7
-
8
- def test_get_all
9
- units = Proj4::Unit.list.sort.collect{ |u| u.id }
10
- assert units.index('km')
11
- assert units.index('m')
12
- assert units.index('yd')
13
- assert units.index('us-mi')
14
- end
15
-
16
- def test_one
17
- unit = Proj4::Unit.get('km')
18
- assert_kind_of Proj4::Unit, unit
19
- assert_equal 'km', unit.id
20
- assert_equal 'km', unit.to_s
21
- assert_equal '1000.', unit.to_meter
22
- assert_equal 'Kilometer', unit.name
23
- assert_equal '#<Proj4::Unit id="km", to_meter="1000.", name="Kilometer">', unit.inspect
24
- end
25
-
26
- def test_compare
27
- u1 = Proj4::Unit.get('km')
28
- u2 = Proj4::Unit.get('km')
29
- assert u1 == u2
30
- end
31
-
32
- def test_failed_get
33
- unit = Proj4::Unit.get('foo')
34
- assert_nil unit
35
- end
36
-
37
- def test_new
38
- assert_raise TypeError do
39
- Proj4::Unit.new
40
- end
41
- end
7
+ class UnitsTest < Test::Unit::TestCase
8
+
9
+ def test_get_all
10
+ units = Proj4::Unit.list.sort.collect{ |u| u.id }
11
+ assert units.index('km')
12
+ assert units.index('m')
13
+ assert units.index('yd')
14
+ assert units.index('us-mi')
15
+ end
42
16
 
17
+ def test_one
18
+ unit = Proj4::Unit.get('km')
19
+ assert_kind_of Proj4::Unit, unit
20
+ assert_equal 'km', unit.id
21
+ assert_equal 'km', unit.to_s
22
+ assert_equal '1000.', unit.to_meter
23
+ assert_equal 'Kilometer', unit.name
24
+ assert_equal '#<Proj4::Unit id="km", to_meter="1000.", name="Kilometer">', unit.inspect
43
25
  end
26
+
27
+ def test_compare
28
+ u1 = Proj4::Unit.get('km')
29
+ u2 = Proj4::Unit.get('km')
30
+ assert u1 == u2
31
+ end
32
+
33
+ def test_failed_get
34
+ unit = Proj4::Unit.get('foo')
35
+ assert_nil unit
36
+ end
37
+
38
+ def test_new
39
+ assert_raise TypeError do
40
+ Proj4::Unit.new
41
+ end
42
+ end
43
+
44
+ end
44
45
  end
45
46
 
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: proj4rb
3
3
  version: !ruby/object:Gem::Version
4
- hash: 15
4
+ hash: 13
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 4
9
- - 0
10
- version: 0.4.0
9
+ - 1
10
+ version: 0.4.1
11
11
  platform: x86-mingw32
12
12
  authors:
13
13
  - Guilhem Vellut
@@ -92,11 +92,12 @@ files:
92
92
  - test/test_prime_meridians.rb
93
93
  - test/test_projection_type.rb
94
94
  - test/test_simple_projection.rb
95
+ - test/test_suite.rb
95
96
  - test/test_transform.rb
96
97
  - test/test_units.rb
97
98
  - lib/1.8/proj4_ruby.so
98
99
  - lib/1.9/proj4_ruby.so
99
- homepage: http://proj4rb.rubyforge.org/
100
+ homepage: https://github.com/cfis/proj4rb
100
101
  licenses: []
101
102
 
102
103
  post_install_message:
@@ -141,5 +142,6 @@ test_files:
141
142
  - test/test_prime_meridians.rb
142
143
  - test/test_projection_type.rb
143
144
  - test/test_simple_projection.rb
145
+ - test/test_suite.rb
144
146
  - test/test_transform.rb
145
147
  - test/test_units.rb