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

Aleksandr Shulman commented on HBASE-7493:
------------------------------------------

This seems like a relatively straightforward task. 

For tests that are written to test offline snapshots:
Basically we'd factor out existing tests and add a boolean parameter indicating 
whether it's online or offline (yes for online). Then, in our test, we would 
wrap all relevant calls to enable and disable table, with the boolean. If it's 
online, then we don't enable/disable the table. By relevant calls, it would be 
the last call to disable at table before a snapshot and the first call to 
enable the table after the snapshot.

For tests that are written to test online snapshots:
We would add a call before and after the snapshot request to disable and then 
enable the table, respectively. We'd wrap these calls with the same logic as 
above and refactor the tests to accept a parameter.

The caveat would be tests that are actually testing table enable/disable during 
snapshots. We have to be careful with those tests.
                
> Refactor snapshotting tests so that all they all are exercised the same way.
> ----------------------------------------------------------------------------
>
>                 Key: HBASE-7493
>                 URL: https://issues.apache.org/jira/browse/HBASE-7493
>             Project: HBase
>          Issue Type: Sub-task
>            Reporter: Jonathan Hsieh
>
> Currently we have two flavors of snapshots -- offline and flush snapshots.  
> We may have a few more with different consistency policies and we should test 
> all of them with the same basic correctness tests (see 
> TestFlushSnapshotFromClient).
> We should refactor or use parameterized tests to make this easy. I prefer 
> refactor, easier to follow and to test only what you want individually.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to