gpx/tests/magellan_test.rb

19 lines
619 B
Ruby
Raw Permalink Normal View History

2006-10-14 15:20:23 +02:00
require 'test/unit'
2013-06-16 01:35:46 +02:00
require 'gpx'
2006-10-14 15:20:23 +02:00
class MagellanTest < Test::Unit::TestCase
2006-10-14 15:20:23 +02:00
MAGELLAN_TRACK_LOG = File.join(File.dirname(__FILE__), "gpx_files/magellan_track.log")
GPX_FILE = File.join(File.dirname(__FILE__), "gpx_files/one_segment.gpx")
def test_convert
GPX::MagellanTrackLog.convert_to_gpx(MAGELLAN_TRACK_LOG, "/tmp/gpx_from_magellan.gpx")
@gpx_file = GPX::GPXFile.new(:gpx_file => "/tmp/gpx_from_magellan.gpx")
end
def test_file_type
assert(GPX::MagellanTrackLog::is_magellan_file?(MAGELLAN_TRACK_LOG))
assert(!GPX::MagellanTrackLog::is_magellan_file?(GPX_FILE))
end
end