DESCRIPTION

Code for testing csv data transfer - Related to CBQE-1376

Change-Id: I96c2e5123820caa7dba6ba81eb570d8ff70291ed


COMMENTS

author: Paige Todd
date: 2013-10-10 08:06:40.291000000

Uploaded patch set 4.

-------------------------------------
author: Esperanza Cherry
date: 2013-10-10 09:05:21.004000000

Patch Set 4: Code-Review-1

(13 comments)

Line:1, pytests/csvdatatest.py -> RestHelper is unused import

Line:3, pytests/csvdatatest.py -> RemoteMachineHelper, RemoteUtilHelp are unused imports

Line:4, pytests/csvdatatest.py -> MemcachedClientHelper unused

Line:21, pytests/csvdatatest.py -> you can use simple construction:
if 'default' in [buket.name for bucket in self.buckets]:
    self.log.info("Loading data to {0}".format(bucket.name))
        task = self.cluster.async_load_gen_docs(self.master,      bucket_to_load.name, self.gen_load, buc
     ket_to_load.kvs[1], 'create')	
        task.result()
 otherwise you can get bucket_to_load is undefined if there is no bucket 'default'
but why you load only in default bucket?

The simplest way is to use:
self._load_doc_data_all_buckets()

Line:32, pytests/csvdatatest.py -> please, use clearer variable names

Line:34, pytests/csvdatatest.py -> please use /opt/backup/ as parameter. better to handle this param base on OS specific. for example: linux/mac( /tmp/backup/), windows(/cygdrive/c/tmp/backup).

Line:35, pytests/csvdatatest.py -> what is remove_folder.format(remove_folder)? please use parameter

Line:41, pytests/csvdatatest.py -> space at the end of string '-b default'

Line:45, pytests/csvdatatest.py -> you don't need to recreate RemoteMachineShellConnection

Line:47, pytests/csvdatatest.py -> extra parameters, you can replace their order in params like:
obj_remote.execute_cbtransfer(destination, source, options)

Line:48, pytests/csvdatatest.py -> space at the end of string '-B standard_bucket0'?

Line:55, pytests/csvdatatest.py -> I guess you can use rest.get_bucket("standard_bucket0")["basicStats"]

Line:57, pytests/csvdatatest.py -> you don't handle situation when there is not basicStats in info.

-------------------------------------
