wasserstand 0.0.3 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/wasserstand/mapper.rb +1 -1
- data/lib/wasserstand/version.rb +1 -1
- data/test/unit/test_wasserstand.rb +1 -1
- data/wasserstand.gemspec +1 -0
- metadata +17 -1
data/lib/wasserstand/mapper.rb
CHANGED
@@ -29,7 +29,7 @@ module Wasserstand
|
|
29
29
|
datum = item.xpath('datum').text
|
30
30
|
uhrzeit = item.xpath('uhrzeit').text
|
31
31
|
|
32
|
-
messdatum = Time.parse("#{datum} #{uhrzeit}")
|
32
|
+
messdatum = TZInfo::Timezone.get('Europe/Berlin').local_to_utc(Time.parse("#{datum} #{uhrzeit}"))
|
33
33
|
wert = item.xpath('messwert').text.sub(',', '.').to_f
|
34
34
|
tendenz = item.xpath('tendenz').text.downcase.to_sym
|
35
35
|
|
data/lib/wasserstand/version.rb
CHANGED
@@ -24,7 +24,7 @@ class TestWasserstand < MiniTest::Unit::TestCase
|
|
24
24
|
def test_single_measurement
|
25
25
|
konstanz_measurements = Waterway['BODENSEE'].levels['KONSTANZ'].measurements
|
26
26
|
|
27
|
-
assert_equal(Time.parse('2012-09-13
|
27
|
+
assert_equal(Time.parse('2012-09-13 18:00:00 UTC'), konstanz_measurements.last.date)
|
28
28
|
assert_equal(380.7, konstanz_measurements.last.value)
|
29
29
|
assert_equal(:gleich, konstanz_measurements.last.trend)
|
30
30
|
end
|
data/wasserstand.gemspec
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: wasserstand
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.4
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -43,6 +43,22 @@ dependencies:
|
|
43
43
|
- - ! '>='
|
44
44
|
- !ruby/object:Gem::Version
|
45
45
|
version: '0'
|
46
|
+
- !ruby/object:Gem::Dependency
|
47
|
+
name: tzinfo
|
48
|
+
requirement: !ruby/object:Gem::Requirement
|
49
|
+
none: false
|
50
|
+
requirements:
|
51
|
+
- - ! '>='
|
52
|
+
- !ruby/object:Gem::Version
|
53
|
+
version: '0'
|
54
|
+
type: :runtime
|
55
|
+
prerelease: false
|
56
|
+
version_requirements: !ruby/object:Gem::Requirement
|
57
|
+
none: false
|
58
|
+
requirements:
|
59
|
+
- - ! '>='
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
46
62
|
- !ruby/object:Gem::Dependency
|
47
63
|
name: minitest
|
48
64
|
requirement: !ruby/object:Gem::Requirement
|