Permalink
Browse files

stop warnings in the test; ref #3280

  • Loading branch information...
matz committed Nov 25, 2016
1 parent 1329529 commit 743c1e7be190eca83a08b95b0f6045cbdc9ba625
Showing with 2 additions and 0 deletions.
  1. +2 −0 mrbgems/mruby-struct/test/struct.rb
@@ -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
@@ -171,6 +172,7 @@
begin
Struct.new("Test", :a)
a = Struct::Test.new("a")
Struct.remove_const :Test

This comment has been minimized.

Show comment
Hide comment
@bouk

bouk Nov 25, 2016

Contributor

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

@bouk

bouk Nov 25, 2016

Contributor

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

This comment has been minimized.

Show comment
Hide comment
@matz

matz Nov 25, 2016

Member

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

@matz

matz Nov 25, 2016

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"))

0 comments on commit 743c1e7

Please sign in to comment.