Skip to content

Commit da07fa5

Browse files
committed
Update test syntax for Minitest
* Update how Minitest is called * Replace `assert_raise` with `assert_raises`
1 parent 524061b commit da07fa5

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

test/test_helper.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,6 @@
1313

1414
require 'closure-compiler'
1515

16-
class MiniTest::Unit::TestCase
16+
class Minitest::Test
1717
include Closure
1818
end

test/unit/closure_compiler_test.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
require 'test_helper'
22

3-
class ClosureCompilerTest < MiniTest::Unit::TestCase
3+
class ClosureCompilerTest < Minitest::Test
44

55
ORIGINAL = "window.hello = function(name) { return console.log('hello ' + name ); }; hello.squared = function(num) { return num * num; }; hello('world');"
66

@@ -47,10 +47,10 @@ def test_jar_and_java_specifiation
4747
end
4848

4949
def test_exceptions
50-
assert_raise(Closure::Error) do
50+
assert_raises(Closure::Error) do
5151
Compiler.new.compile('1++')
5252
end
53-
assert_raise(Closure::Error) do
53+
assert_raises(Closure::Error) do
5454
Compiler.new.compile('obj = [1 2, 3]')
5555
end
5656
end

0 commit comments

Comments
 (0)