zzak
4370f84653
* lib/test/unit/assertions.rb: [DOC] better example for assert_send()
...
Patch by Andrew Grimm [Bug #8975 ]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43597 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-11-09 05:12:45 +00:00
nobu
ac6268dbf0
assertions.rb: fix omitted message
...
* lib/test/unit/assertions.rb (assert_raise_with_message): remove
omitted message by splatting nil.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43374 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-10-21 14:53:31 +00:00
nobu
f7b68ecfcf
assertions.rb: ignore nil message
...
* lib/test/unit/assertions.rb (assert): allow nil message and just
ignore.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43283 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-10-14 19:14:13 +00:00
nobu
9ef55da910
test/unit/assertions.rb: return exception
...
* lib/test/unit/assertions.rb (assert_raise_with_message): return
raised exception same as assert_raise.
* test/ruby, test/-ext-: use assert_raise_with_message.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43212 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-10-09 08:43:12 +00:00
nobu
91d28c4ffb
assertions.rb: assert_throw
...
* lib/test/unit/assertions.rb (Test::Unit::Assertions#assert_throw):
assertion for throw. MiniTest::Assertions#assert_throws discards
the cautht value.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42960 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-09-17 06:53:21 +00:00
nobu
246ff7cb68
assertions.rb: assert_nothing_thrown returns the result
...
* lib/test/unit/assertions.rb (Test::Unit::Assertions#assert_nothing_thrown):
returns the result of the given block.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42959 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-09-17 06:52:33 +00:00
zzak
b8ef79884b
* lib/test/: [DOC] Document Test::Unit, hide most submodules and
...
classes from rdoc. Since lib/test is only present as a compatibility
layer with the legacy test suite many test/unit users will be using
minitest or the test/unit gem instead. It is recommended to use one
of these alternatives for writing new tests.
This patch was based on a patch submitted by Steve Klabnik.
[ruby-core:56694] [Bug #8778 ]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42632 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-08-19 17:36:03 +00:00
nobu
9d93d4df6f
test/unit: assert_raise_with_message
...
* lib/test/unit/assertions.rb (assert_raise_with_message): move from
test/fileutils/test_fileutils.rb. this is still experimental and
the interface may be changed.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41790 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-07-05 02:29:49 +00:00
nobu
9efcd10371
assertions.rb: remove UNASSIGNED
...
* lib/test/unit/assertions.rb (Test::Unit::Assertions#assert):
UNASSIGNED is not a valid message.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40330 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-04-17 02:39:02 +00:00
nobu
49a22e173b
assertions.rb: private flag
...
* lib/test/unit/assertions.rb (assert_respond_to): accept optional
include-private flag.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39742 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-03-13 05:51:29 +00:00
nobu
1a633537f8
assertions.rb: split lines
...
* lib/test/unit/assertions.rb (Test::Unit::Assertions#message): split
msg and default procs by period and newline.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39639 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-03-08 07:09:14 +00:00
nobu
3d88196632
assertions.rb: allow proc
...
* lib/test/unit/assertions.rb (Test::Unit::Assertions#message):
convert msg by call if it is a proc, as well as assert.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39638 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-03-08 07:02:37 +00:00
nobu
799680354e
* lib/test/unit/assertions.rb (build_message): skip escaped
...
question marks.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34589 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-02-14 06:06:40 +00:00
usa
7491541e16
* test/unit/assertions.rb (MINI_DIR): quick dirty hack to get rid of
...
warnings when using assert/assert_respond_to.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33784 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-11-18 04:21:23 +00:00
nobu
e50c05f7f6
* lib/test/unit/assertions.rb (assert_send, assert_not_send):
...
parenthesize non-empty arguments.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33424 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-10-07 08:54:30 +00:00
nobu
53fd35c304
* lib/test/unit/assertions.rb (Test::Unit::Assertions#assert_send): fix message.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33259 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-09-12 13:24:19 +00:00
nobu
1161616768
* lib/test/unit/assertions.rb (assert_send): make arguments in
...
the default message clearer.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33251 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-09-12 03:40:49 +00:00
sorah
8c812c9a03
* lib/test/unit/assertions.rb: Import documentation patch by Justin
...
Collins. [ruby-core:37225] [Feature #4903 ]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32488 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-07-10 06:11:49 +00:00
naruse
09c8651387
Don't break test-all.
...
Revert "* lib/test/unit/assertions.rb (Test::Unit::Assertions#skip): reason to"
This reverts commit r31982.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31984 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-06-10 06:45:21 +00:00
nobu
3bc5b309be
* lib/test/unit/assertions.rb (Test::Unit::Assertions#skip): reason to
...
skip should be explained.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31982 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-06-10 04:04:41 +00:00
nobu
7f46fadd9d
* lib/test/unit.rb (assert_include): add alias.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30853 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-02-12 14:17:54 +00:00
nobu
180bf48fea
* lib/test/unit/assertions.rb (assert_no_match): alias for
...
backward compatibility.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30838 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-02-11 05:33:21 +00:00
kosaki
e66eec9284
* lib/test/unit/assertions.rb (Test::Unit::Assertions#assert):
...
revert r30796. r30797 and r30798 are an alternative fix.
[ruby-dev:43174]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30800 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-02-05 13:06:14 +00:00
nobu
dd9341f02b
* lib/test/unit/assertions.rb (assert_block): move from
...
test/fileutils/fileasserts.rb.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30798 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-02-05 12:22:27 +00:00
kosaki
49f8799af4
* lib/test/unit/assertions.rb (Test::Unit::Assertions#assert):
...
msg can be passed nil. [Bug #4371 ] [ruby-dev:43174]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30796 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-02-05 07:50:12 +00:00
nobu
cb9ffb8d1c
* lib/test/unit/assertions.rb (Test::Unit::Assertions#assert):
...
assertion message must not be nil.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29555 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-22 05:50:17 +00:00
naruse
e1d1571256
* lib/test/unit/assertions.rb (Test::Unit::Assertions#assert):
...
treat nil case. Please run test-all before commit such change.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29554 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-22 05:10:40 +00:00
ryan
b3ee43bb6e
Cleaned up clevar in test/unit's override of assert
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29553 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-21 21:15:06 +00:00
shyouhei
36cfaa8052
* test/net/imap/test_imap.rb: resurrection of r29259.
...
this change depends on minitest 1.7.1.
* lib/test/unit/assertions.rb: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29348 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-09-27 06:28:59 +00:00
shyouhei
cc9b6ba611
reverting; http://rubyforge.org/tracker/?func=detail&atid=4099&aid=28566&group_id=1040
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29260 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-09-15 07:56:04 +00:00
shyouhei
6bab4ea991
* lib/test/unit/assertions.rb (Test::Unit::Assertions::assert_nothing_raised):
...
should properly ignore MiniTest::Skip
* lib/minitest/unit.rb (MiniTest::Assertions::assert_raises):
ditto.
* test/net/imap/test_imap.rb: Properly skip SSL tests when
localhost is not 127.0.0.1.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29259 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-09-15 06:01:00 +00:00
nobu
9ad152e555
* lib/test/unit/assertions.rb (Test::Unit::Assertions#assert):
...
keep the first trace.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27577 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-05-01 13:41:10 +00:00
nobu
8657912211
* lib/test/unit/assertions.rb (Test::Unit::Assertions#assert):
...
fixed filtering. [ruby-core:29908]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27576 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-05-01 13:27:49 +00:00
nobu
9d094c7a25
* lib/test/unit/assertions.rb (Test::Unit::Assertions#assert):
...
filter out traces in minitest directory. [ruby-core:29908]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27572 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-05-01 00:43:10 +00:00
nobu
11caac1663
* lib/test/unit/assertions.rb (Test::Unit::Assertions#assert):
...
assertion message must be String or Proc. suggested by caleb
clausen at [ruby-core:29884].
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27568 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-04-30 15:26:34 +00:00
nobu
4c205de3e6
* lib/test/unit/assertions.rb (Test::Unit::Assertions#assert):
...
reverted. [ruby-core:29872]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27543 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-04-29 05:24:52 +00:00
nobu
33cf9431da
* lib/test/unit/assertions.rb (Test::Unit::Assertions#assert): reject
...
non-boolean values. [ruby-core:29868]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27541 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-04-29 03:16:24 +00:00
akr
0eddab8404
* lib/test/unit/assertions.rb (assert_equal): use Time#subsec if nsec
...
is not enough to distinguish arguments.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25158 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-09-29 13:22:27 +00:00
akr
0f82f65cee
* lib/test/unit/assertions.rb: don't define assert_not_* if already
...
overridden.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22664 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-02-27 13:10:07 +00:00
nobu
8fc45476eb
* lib/test/unit/assertions.rb (Test::Unit::Assertions): aliases
...
assert_not_ methods.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22331 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-02-15 12:22:50 +00:00
akr
a0b15459ef
* lib/test/unit/assertions.rb (assert_equal): show class in failure
...
message if meaningful.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@21923 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-01-31 13:51:46 +00:00
akr
966675c860
* lib/test/unit/assertions.rb
...
(Test::Unit::Assertions#assert_nothing_raised): supress warning.
[ruby-core:21312]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@21908 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-01-30 15:09:17 +00:00
nobu
e501209104
* lib/test/unit/assertions.rb (assert_respond_to): gets rid of
...
overcounting. [ruby-dev:37703]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@21887 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-01-30 02:03:32 +00:00
nobu
6b0304a5d7
* lib/test/unit/assertions.rb (assert_nothing_raised): removes the
...
current trace to get rid of an issue of MiniTest::Unit#location.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@21449 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-01-12 08:23:07 +00:00
akr
d45c4a8107
* lib/test/unit/assertions.rb (assert_no_match): don't count up as two
...
assertions.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@21376 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-01-07 15:33:17 +00:00
akr
ace35ac66c
* lib/test/unit/assertions.rb (assert_equal): show small differences
...
for Regexp and Float.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@20943 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-12-23 09:34:08 +00:00
akr
c8cbfe7deb
* lib/test/unit/assertions.rb (assert_nothing_raised): increment
...
assertion count. [ruby-dev:37480]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@20915 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-12-22 12:11:43 +00:00
akr
cbc6a104b2
* lib/test/unit/assertions.rb: extracted from lib/test/unit.rb.
...
lib/test/unit/testcase.rb: ditto.
at asakusa.rb. [ruby-core:20014]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@20632 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-12-11 10:40:24 +00:00
akr
0ebf9b1763
* lib/test/unit: removed test/unit.
...
* lib/test/unit.rb: new compatibility layer using minitest.
* bin/testrb: use above.
* test/runner.rb: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19800 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-10-16 13:55:09 +00:00
ryan
30e76a6af3
Restored test/unit
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19739 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-10-10 01:17:21 +00:00