hbase-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "jiraposter@reviews.apache.org (Commented) (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HBASE-4555) TestShell seems passed, but actually errors seen in test output file
Date Tue, 11 Oct 2011 23:03:12 GMT

    [ https://issues.apache.org/jira/browse/HBASE-4555?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13125466#comment-13125466
] 

jiraposter@reviews.apache.org commented on HBASE-4555:
------------------------------------------------------


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/2351/
-----------------------------------------------------------

Review request for hbase.


Summary
-------

HBase shell unit cases are in ruby. Ruby unit test runner Test::Unit::AutoRunner.run only
prints unit tests assertion failures to console by default. So it actually swallows all the
assertion errors from ruby, and junit cannot notice any shell test failure. 

Fixed the test_runner.rb to chech the return value and throw a runtime exception, so that
TestShell can get to know there is something wrong by test errors. 

Also fixed 7 previously existing failed test cases. 

In addition, after HBase-1730, there's no need to disable a table before altering a table.
Changed the test cases accordingly. 


This addresses bug HBase-4555.
    https://issues.apache.org/jira/browse/HBase-4555


Diffs
-----

  src/test/ruby/hbase/admin_test.rb 5e491e4 
  src/test/ruby/tests_runner.rb 0dbc5ce 

Diff: https://reviews.apache.org/r/2351/diff


Testing
-------

TestShell passed locally. 


Thanks,

Mingjie


                
> TestShell seems passed, but actually errors seen in test output file
> --------------------------------------------------------------------
>
>                 Key: HBASE-4555
>                 URL: https://issues.apache.org/jira/browse/HBASE-4555
>             Project: HBase
>          Issue Type: Test
>          Components: test
>            Reporter: Mingjie Lai
>            Assignee: Mingjie Lai
>         Attachments: 4555.diff
>
>
> When I was making test cases for 4554, I saw a weird issue that TestShell seems to pass,
but actually I saw error messages in the output file.
> {code}
> -------------------------------------------------------
>  T E S T S
> -------------------------------------------------------
> Running org.apache.hadoop.hbase.client.TestShell
> Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 39.252 sec
> Results :
> Tests run: 1, Failures: 0, Errors: 0, Skipped: 0
> {code}
> Error messages in org.apache.hadoop.hbase.client.TestShell-output.txt:
> {code}
> ...
>   6) Error:
> test_alter_should_support_shortcut_DELETE_alter_specs(Hbase::AdminAlterTableTest):
> ArgumentError: There should be at least one argument but the table name
>     /home/mlai/git/hbase-private/src/test/ruby/../../main/ruby/hbase/admin.rb:307:in
`alter'
>     ./src/test/ruby/hbase/admin_test.rb:271:in `test_alter_should_support_shortcut_DELETE_alter_specs'
>     org/jruby/RubyProc.java:268:in `call'
>     org/jruby/RubyKernel.java:2038:in `send'
>     org/jruby/RubyArray.java:1572:in `each'
>     org/jruby/RubyArray.java:1572:in `each'
>     
>   7) Error:
> test_split_should_work(Hbase::AdminMethodsTest):
> ArgumentError: wrong number of arguments (1 for 2)
>     ./src/test/ruby/hbase/admin_test.rb:99:in `test_split_should_work'
>     org/jruby/RubyProc.java:268:in `call'
>     org/jruby/RubyKernel.java:2038:in `send'
>     org/jruby/RubyArray.java:1572:in `each'
>     org/jruby/RubyArray.java:1572:in `each'
>     
> 192 tests, 259 assertions, 1 failures, 6 errors
> Done with tests! Shutting down the cluster...
> 2011-10-07 16:46:14,760 INFO  [main] hbase.HBaseTestingUtility(551): Shutting down minicluster
> 2011-10-07 16:46:14,760 DEBUG [main] util.JVMClusterUtil(214): Shutting down HBase Cluster
> {code}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message