aboutsummaryrefslogtreecommitdiffstats
path: root/lib/test
Commit message (Collapse)AuthorAgeFilesLines
...
* tests: customizable colorsnobu2012-05-081-1/+1
| | | | | | | * bootstraptest/runner.rb, lib/test/unit.rb, sample/test.rb: customizable colors. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35586 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* lib/test/unit.rb: old behavior if verbosenobu2012-05-081-2/+2
| | | | | | | * lib/test/unit.rb (Test::Unit::Runner#_prepare_run): keep the old behavior if --verbose option is given. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35585 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* lib/test/unit.rb: initialize instace variablenobu2012-05-071-1/+1
| | | | | | | * lib/test/unit.rb (Test::Unit::Runner#output): suppress uninitialized instance variable warnings. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35581 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* lib/test/unit.rb: use local outputnobu2012-05-071-1/+5
| | | | | | | | * lib/test/unit.rb (Test::Unit::Runner#output): prefer local output to get rid of unexpected side effect in test/minitest/metametameta.rb. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35580 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* lib/test/unit.rb: test name in $0nobu2012-05-071-0/+11
| | | | | | | * lib/test/unit.rb (MiniTest#run_test): show the running test in $0. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35579 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* lib/test/unit.rb: output in status linenobu2012-05-071-24/+97
| | | | | | | | * lib/test/unit.rb (Test::Unit::StatusLineOutput): new class to output in status line. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35578 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* lib/test/unit.rb: refactoring pukenobu2012-05-071-15/+7
| | | | | | | | * lib/test/unit.rb (Test::Unit::Runner#puke): modify only result and drop useless reports, not override entirely. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35576 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb (Test::Unit::RequireFiles#non_options): expandnobu2012-05-021-1/+1
| | | | | | | real path to get rid of loading same files via symlinks. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35522 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb (Test::Unit:Runner::Worker#_run_suites):naruse2012-04-111-0/+1
| | | | | | call GC.start before running the test suites. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35301 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb (terminal_width, del_status_line, put_status):nobu2012-03-292-16/+38
| | | | | | | extract as methods. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35169 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb: Put error message into STDERR if failed to lanchsorah2012-03-112-23/+38
| | | | | | | | | worker (job) process. [ruby-dev:44802] [Bug #5577] * lib/test/unit/parallel.rb: If failed to increment_io, exit with code 2. [ruby-dev:44802] [Bug #5577] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34968 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb (Test::Unit::Runner#puke): skips with nonobu2012-02-271-0/+1
| | | | | | | messages should be trivial. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34826 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb (setup_options): add option "--retry" as oppositesorah2012-02-221-3/+9
| | | | | | for "--no-retry" git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34741 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb (setup_options): add option "--show-skip" tosorah2012-02-221-0/+4
| | | | | | cancel "--hide-skip" (-q) git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34740 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit/assertions.rb (build_message): skip escapednobu2012-02-141-1/+1
| | | | | | | question marks. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34589 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit/parallel.rb: use pack("m0") instead ofkazu2012-01-022-5/+5
| | | | | | | pack("m").gsub("\n",""). * lib/test/unit.rb (Test::Unit::Runner::Worker#run): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34171 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb (Test::Unit::Runner::Worker#run): usekazu2012-01-021-1/+1
| | | | | | File.basename with suffix instead of gsub. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34170 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb (Test::Unit::Runner#_run_parallel): find maykazu2012-01-021-1/+2
| | | | | | return nil and nil can not dup. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34168 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb (Test::Unit::Runner::Worker#_run_parallels): fixnagachika2011-12-291-1/+3
| | | | | | | premature exit when all workers' status are :ready or :prepare. [ruby-dev:45061] [Bug #5822] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34155 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb (Worker#close): "closing IO if IO is closed"sorah2011-12-271-1/+1
| | | | | | should be "closing IO if IO isn't closed" git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34142 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb: Avoid zombie processes on "--separate" optionsorah2011-12-261-1/+4
| | | | | | added at r34121. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34128 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb (_run_parallel):sorah2011-12-252-8/+35
| | | | | | | | | | | New option "--separate" for test/unit; when running tests with this option, a job process will be restarted after one testcase has done. This means all testcases will run with separated process. * lib/test/unit/parallel.rb: Fix for above. Now parallel.rb puts "ready!" for first ready, "ready" for afters. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34121 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * test/unit/assertions.rb (MINI_DIR): quick dirty hack to get rid ofusa2011-11-181-2/+4
| | | | | | | warnings when using assert/assert_respond_to. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33784 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb (Test::Unit::Options#non_options): options[:ruby]akr2011-11-051-1/+1
| | | | | | | | | should be an array. This fixes "./ruby test/runner.rb test/testunit/test_parallel.rb" [ruby-dev:44782] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33643 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit/assertions.rb (assert_send, assert_not_send):nobu2011-10-071-2/+2
| | | | | | parenthesize non-empty arguments. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33424 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit/assertions.rb (Test::Unit::Assertions#assert_send): fix message.nobu2011-09-121-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33259 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit/assertions.rb (assert_send): make arguments innobu2011-09-121-0/+52
| | | | | | the default message clearer. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33251 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb (_run_suites): Now reports are written thesorah2011-09-061-0/+8
| | | | | | | | | | | | | following order: Skip, Failure, Error. [Feature #5282] * test_sorting.rb: test for above. * test4test_sorting.rb: Ditto. * lib/test/unit.rb (run): Put RUBY_DESCIPTION before quitting. [Feature #5282] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33205 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb(Test::Unit::Options#process_args): Fix bug.sorah2011-07-121-21/+14
| | | | | | Fix process_args didn't return `@option` after r30939. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32526 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb: Add new class variable `@@testfile_prefix`.sorah2011-07-101-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is for changing test name prefix. (For testing) * test/testunit/tests_for_parallel/ptest_first.rb: Renamed from test_first.rb * test/testunit/tests_for_parallel/ptest_second.rb: Renamed from test_second.rb * test/testunit/tests_for_parallel/ptest_third.rb: Renamed from test_third.rb * test/testunit/tests_for_parallel/ptest_forth.rb: Renamed from test_forth.rb * test/testunit/tests_for_parallel/runner.rb: Remove misc.rb * test/testunit/tests_for_parallel/ptest_first.rb: ditto. * test/testunit/tests_for_parallel/ptest_second.rb: ditto. * test/testunit/tests_for_parallel/ptest_third.rb: ditto. * test/testunit/tests_for_parallel/ptest_forth.rb: ditto. * test/testunit/tests_for_parallel/misc.rb: Removed because no longer needed. * test/testunit/test_parallel.rb: Fix assertions for above. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32496 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit/assertions.rb: Import documentation patch by Justinsorah2011-07-101-3/+106
| | | | | | Collins. [ruby-core:37225] [Feature #4903] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32488 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit/parallel.rb: Override Test::Unit::TestCase#on_parallel_worker?sorah2011-06-191-7/+13
| | | | | | | | | only when $0 == __FILE__. * lib/test/unit/parallel.rb: Run Test::Unit::Worker.run only when $0 == __FILE__. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32171 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * test/testunit/test_parallel.rb: Fix Regexp for test.sorah2011-06-162-0/+10
| | | | | | | | | | | | | * test/testunit/tests_for_parallel/test_third.rb: Use Test::Unit::TestCase#on_parallel_worker? for detecting worker. * lib/test/unit/testcase.rb(Test::Unit::TestCase#on_parallel_worker?): New Method Test::Unit::TestCase#on_parallel_worker? returns true when a testcase is running on parallel worker. * lib/test/unit/parallel.rb(Test::Unit::TestCase#on_parallel_worker?): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32123 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb(Test::Unit::Runner#_run_parallel): Ignore -j0sorah2011-06-151-0/+5
| | | | | | because it makes blocking forever by IO.select. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32109 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb (Test::Unit::GlobOption#non_options): fix typo.mrkn2011-06-131-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32046 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb (Test::Unit::GlobOption#non_options): should runnobu2011-06-111-1/+1
| | | | | | with 1.8. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32002 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Don't break test-all.naruse2011-06-101-5/+0
| | | | | | | | 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
* * lib/test/unit/assertions.rb (Test::Unit::Assertions#skip): reason tonobu2011-06-101-0/+5
| | | | | | skip should be explained. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31982 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb(Test::Unit::Runner#puke):sorah2011-06-061-0/+21
| | | | | | | | Add overriding from MiniTest::Unit#puke. This reverts minitest's fix that skip messages are hidden when not verbose mode (-v option). To hide skip messages, use --hide-skip option instead. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31934 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit/parallel.rb: Keep $stdin, $stdout before run testcasesorah2011-06-031-2/+8
| | | | | | | and restore after run. Because some test break $stdin, $stdout. Fixes [Bug #4433] [ruby-core:35353] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31910 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Imported minitest 2.2.2 (r6281)ryan2011-06-011-0/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31899 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit/parallel.rb: Never Ignore SIGINT. When receivedsorah2011-05-232-6/+36
| | | | | | | | | Interrupt, immediately puts result and exit. [ruby-dev:43571] * lib/test/unit.rb: When received Interrupt, wait results from workers and correct them. [ruby-dev:43571] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31708 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb: Add option for hiding skip messages when testsorah2011-05-101-0/+5
| | | | | | | | | ends. #4657 * test/testunit/test_hideskip.rb, test/testunit/test4test_hideskip.rb: test for above. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31502 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb (Test::Unit::Options#setup_options): set possiblenobu2011-04-141-3/+4
| | | | | | values for completion. no conversion is needed. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31285 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb (Test::Unit::Runner::Worker#initialize): usenobu2011-04-141-5/+5
| | | | | | positional arguments instead of keyword arguments. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31284 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb (Test::Unit::Runner#jobs_status): io/console maynobu2011-04-141-6/+10
| | | | | | | not be available. use 80 as the last resort if IO#winsize and COLUMNS are unavailable. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31283 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb (Test::Unit::Runner::Worker#died): rename using anobu2011-04-141-4/+4
| | | | | | verb. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31282 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb (Test::Unit::Runner#_run_parallel): check if workernobu2011-04-141-3/+4
| | | | | | is signaled and use its exit status. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31281 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit.rb (Test::Unit::Runner::Worker#dead): no longer @innobu2011-04-141-2/+1
| | | | | | and @out are separated. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31280 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/test/unit/parallel.rb: remove unused variable.naruse2011-03-211-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31142 b2dd03c8-39d4-4d8f-98ff-823fe69b080e