def test_set_value_creates_batch_list(self): args = self._parse_set_command('x=1', 'y=1') config.do_config(args) batch_list = self._read_target_file_as(BatchList) self.assertEqual(1, len(batch_list.batches)) batch_header = BatchHeader() batch_header.ParseFromString(batch_list.batches[0].header) self.assertEqual(2, len(batch_header.transaction_ids))
def test_set_value_creates_batch_list(self): subprocess.run(shlex.split( 'sawset proposal create -k {} -o {} x=1 y=1'.format( self._priv_file, os.path.join(self._temp_dir, 'myconfig.batch')))) batch_list = self._read_target_file_as(BatchList) self.assertEqual(1, len(batch_list.batches)) batch_header = BatchHeader() batch_header.ParseFromString(batch_list.batches[0].header) self.assertEqual(2, len(batch_header.transaction_ids))