Skip to content

Commit

Permalink
stop warnings in the test; ref #3280
Browse files Browse the repository at this point in the history
  • Loading branch information
matz committed Nov 25, 2016
1 parent 1329529 commit 743c1e7
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions mrbgems/mruby-struct/test/struct.rb
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,7 @@
end

assert("Struct.new removes existing constant") do
skip "redefining Struct with same name cause warnings"
begin
assert_not_equal Struct.new("Test", :a), Struct.new("Test", :a, :b)
ensure
Expand All @@ -171,6 +172,7 @@
begin
Struct.new("Test", :a)
a = Struct::Test.new("a")
Struct.remove_const :Test

This comment has been minimized.

Copy link
@bouk

bouk Nov 25, 2016

Contributor

This makes the test invalid, it won't fail on previous versions

This comment has been minimized.

Copy link
@matz

matz Nov 25, 2016

Author Member

I know, but I don't want to ignore warnings in the test.

Struct.new("Test", :a, :b)
assert_raise(TypeError) do
a.initialize_copy(Struct::Test.new("a", "b"))
Expand Down

0 comments on commit 743c1e7

Please sign in to comment.