12件ヒット
[1-12件を表示]
(0.023秒)
キーワード
-
irb
/ completion (11) -
test
/ unit (1)
検索結果
先頭2件
-
irb
/ completion (13.0) -
irb の completion 機能を提供するライブラリです。
...d instance_of?
initialize install_aliases instance_variables
irb(main):001:0> inspect
"main"
irb(main):002:0> foo = Object.new
#<Object:0x4027146c>
"変数名." の後に [Tab] を押すと, そのオブジェクトのメソッド一覧がでます.
irb(main):003:0> f......singleton_methods
foo.class foo.instance_of? foo.taint
foo.clone foo.instance_variables foo.tainted?
foo.display foo.is_a? foo.to_a
foo.dup foo.kind_of? foo.to_s
foo.eql? foo.method... -
test
/ unit (13.0) -
ユニットテストを行うためのライブラリです。
...が必ず呼ばれます。
require 'test/unit'
require 'foo'
class TC_Foo < Test::Unit::TestCase
def setup
@obj = Foo.new
end
# def teardown
# end
def test_foo
assert_equal("foo", @obj.foo)
end
def test_bar
assert_equ......すると help も表示されます。
$ ruby test_foo.rb --help
Usage: test_foo [options]
minitest options:
-h, --help Display this help.
-s, --seed SEED Sets random seed
-v, --verbose Verbose. Show progress process......Base directory of test suites.
-x, --exclude PATTERN Exclude test files on pattern.
-Idirectory Add library load path
--[no-]gc-stress Set GC.stress as true
複数のテストを一度に行う場合、以下のように書いた...