summaryrefslogtreecommitdiff
path: root/ext/-test-
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2016-05-22 07:27:02 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2016-05-22 07:27:02 +0000
commit006634b4891fdf274bfa212ed74e696280a5d2dd (patch)
treea9993326ab7c38cff3827792b6d50a3c1a6d164a /ext/-test-
parent78c5ca70744e85f8468147ddc362962bcd987d30 (diff)
-test-/integer
* ext/-test-/integer/core_ext.c: move testutil/integer.c. * test/lib/-test-/integer.rb: extract implementation details from test/unit/assertions.rb. [Bug #12408] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55114 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/-test-')
-rw-r--r--ext/-test-/integer/core_ext.c (renamed from ext/-test-/testutil/integer.c)2
-rw-r--r--ext/-test-/testutil/extconf.rb8
-rw-r--r--ext/-test-/testutil/init.c11
3 files changed, 1 insertions, 20 deletions
diff --git a/ext/-test-/testutil/integer.c b/ext/-test-/integer/core_ext.c
index da5812c..6d64cdb 100644
--- a/ext/-test-/testutil/integer.c
+++ b/ext/-test-/integer/core_ext.c
@@ -21,7 +21,7 @@ rb_int_to_bignum(VALUE x)
}
void
-Init_integer(VALUE klass)
+Init_core_ext(VALUE klass)
{
rb_define_method(rb_cInteger, "bignum?", int_bignum_p, 0);
rb_define_method(rb_cInteger, "fixnum?", int_fixnum_p, 0);
diff --git a/ext/-test-/testutil/extconf.rb b/ext/-test-/testutil/extconf.rb
deleted file mode 100644
index 157a3d6..0000000
--- a/ext/-test-/testutil/extconf.rb
+++ /dev/null
@@ -1,8 +0,0 @@
-# frozen_string_literal: false
-$INCFLAGS << " -I$(topdir) -I$(top_srcdir)"
-$srcs = Dir[File.join($srcdir, "*.{#{SRC_EXT.join(%q{,})}}")]
-inits = $srcs.map {|s| File.basename(s, ".*")}
-inits.delete("init")
-inits.map! {|s|"X(#{s})"}
-$defs << "-DTEST_INIT_FUNCS(X)=\"#{inits.join(' ')}\""
-create_makefile("-test-/testutil")
diff --git a/ext/-test-/testutil/init.c b/ext/-test-/testutil/init.c
deleted file mode 100644
index cf2804d..0000000
--- a/ext/-test-/testutil/init.c
+++ /dev/null
@@ -1,11 +0,0 @@
-#include "ruby.h"
-
-#define init(n) {void Init_##n(VALUE klass); Init_##n(klass);}
-
-void
-Init_testutil(void)
-{
- VALUE mBug = rb_define_module("Bug");
- VALUE klass = rb_define_class_under(mBug, "TestUtil", rb_cObject);
- TEST_INIT_FUNCS(init);
-}