Sha256: e624c3255c3d415955519ba7d2217de1a77b165b26f1526b37226587dd7278ec
Contents?: true
Size: 591 Bytes
Versions: 1
Compression:
Stored size: 591 Bytes
Contents
require File.expand_path('test_helper', File.dirname(__FILE__)) require 'net/http' class SetupTest < Test::Unit::TestCase SDK_DOWNLOAD_PAGE = 'http://developer.android.com/sdk/index.html?hl=sk' def test_if_page_still_exists uri = URI.parse(SDK_DOWNLOAD_PAGE) res = Net::HTTP.get_response(uri) assert_equal 200, res.code.to_i end def test_if_regex_still_applies_to_sdk regex = '(\>installer_.*.exe)' page_content = Net::HTTP.get(URI.parse(SDK_DOWNLOAD_PAGE)) link = page_content.scan(/#{regex}/).to_s assert_match /(\d+).(\d+).(\d+)/, link end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
ruboto-1.1.0 | test/ruboto_setup_test.rb |