示例#1
0
 def test_get_summary(self):
     rand_name = self._make_tmp_name()
     args = ['mtbls-get-factors-summary', _STUDY, rand_name]
     try:
         isaslicer.main(args)
         self._assert_not_empty_json_data(rand_name)
     finally:
         self._clean_output(rand_name)
示例#2
0
 def test_get_factor_values_queries(self):
     rand_name = self._make_tmp_name()
     args = ['mtbls-get-factor-values', _STUDY, "Compound", rand_name]
     try:
         isaslicer.main(args)
         self._assert_not_empty_json_data(rand_name)
     finally:
         self._clean_output(rand_name)
示例#3
0
 def test_get_study_json(self):
     rand_name = self._make_tmp_name()
     args = ['mtbls-get-study', _STUDY, '--isa-format', "isa-json", rand_name]
     try:
         isaslicer.main(args)
         self._assert_not_empty_folder(rand_name)
     finally:
         self._clean_output(rand_name)
示例#4
0
 def test_isatab_get_factor_values_queries(self):
     rand_name = self._make_tmp_name()
     args = ['isa-tab-get-factor-values', self._STUDY_PATH, "Gender", rand_name]
     try:
         isaslicer.main(args)
         self._assert_not_empty_json_data(rand_name)
     finally:
         self._clean_output(rand_name)
示例#5
0
 def test_get_data_files_with_queries(self):
     rand_name = self._make_tmp_name()
     args = ['mtbls-get-data-list', _STUDY, rand_name, '--json-query',
             '{"Compound":"control 1"}']
     try:
         isaslicer.main(args)
         self._assert_not_empty_json_data(rand_name)
     finally:
         self._clean_output(rand_name)
示例#6
0
 def test_isatab_get_data_files_list_with_queries(self):
     rand_name = self._make_tmp_name()
     args = ['isa-tab-get-data-list', self._STUDY_PATH, rand_name, '--json-query',
             '{"Gender":"Male"}']
     try:
         isaslicer.main(args)
         self._assert_not_empty_json_data(rand_name)
     finally:
         self._clean_output(rand_name)
示例#7
0
 def test_get_study_archive(self):
     rand_name = self._make_tmp_name()
     fmt = 'zip'
     args = ['mtbls-get-study-archive', '--format', fmt, _STUDY, rand_name]
     archive_name = "{}.{}".format(rand_name, fmt)
     try:
         isaslicer.main(args)
         self.assertTrue(os.path.exists(archive_name))
     finally:
         self._clean_output(archive_name)