use minitest instead of test-unit
This commit is contained in:
parent
28eb4dc47f
commit
eb4ed5dbca
@ -7,12 +7,9 @@ rescue Bundler::BundlerError => e
|
||||
$stderr.puts "Run `bundle install` to install missing gems"
|
||||
exit e.status_code
|
||||
end
|
||||
require 'test/unit'
|
||||
require 'minitest/autorun'
|
||||
require 'shoulda'
|
||||
|
||||
$LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
||||
$LOAD_PATH.unshift(File.dirname(__FILE__))
|
||||
require 'swot'
|
||||
|
||||
class Test::Unit::TestCase
|
||||
end
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
# encoding: UTF-8
|
||||
require 'helper'
|
||||
|
||||
class TestEmail < Test::Unit::TestCase
|
||||
class TestEmail < MiniTest::Test
|
||||
should "recognizes academic email addresses and domains" do
|
||||
assert_equal Swot::is_academic?('lreilly@stanford.edu'), true
|
||||
assert_equal Swot::is_academic?('LREILLY@STANFORD.EDU'), true
|
||||
@ -66,7 +66,7 @@ class TestEmail < Test::Unit::TestCase
|
||||
end
|
||||
|
||||
should "not err on tld-only domains" do
|
||||
assert_nothing_raised { Swot::is_academic? ".com" }
|
||||
Swot::is_academic? ".com"
|
||||
assert_equal false, Swot::is_academic?(".com")
|
||||
end
|
||||
end
|
||||
|
||||
Loading…
Reference in New Issue
Block a user