def run(self, ctx): example_path = futils.get_example_path(ctx, 'pmem2', 'redo') file_path = ctx.create_holey_file(self.file_size, 'testfile0') for x in range(1, 100): ctx.exec(example_path, "add", file_path, x, x) ctx.exec(example_path, "check", file_path) ctx.exec(example_path, "print", file_path, stdout_file='out3.log')
def run(self, ctx): example_path = futils.get_example_path(ctx, 'pmem2', 'log') file_path = ctx.create_holey_file(self.file_size, 'testfile0') args = ['appendv', '4', 'PMDK ', 'is ', 'the best ', 'open source ', 'append', 'project in the world.', 'dump', 'rewind', 'dump', 'appendv', '2', 'End of ', 'file.', 'dump'] ctx.exec(example_path, file_path, *args, stdout_file='out2.log')
def run(self, ctx): example_path = futils.get_example_path(ctx, 'pmem2', 'map_multiple_files') args = [] for x in range(1, 10): file_path = ctx.create_holey_file(self.file_size, 'testfile{}'.format(x)) args.append(file_path) ctx.exec(example_path, *args, stdout_file='out4.log')
def run(self, ctx): example_path = futils.get_example_path(ctx, 'pmemobj', 'mapcli', dirname='map') testfile = os.path.join(ctx.testdir, 'testfile1') program_args = ' '.join([ctx.parameters(), testfile]) fun_name = 'map_create' self._run_gdb(example_path, program_args, fun_name) ctx.exec(example_path, ctx.parameters(), testfile, std_input=self.input)
def run(self, ctx): example_path = futils.get_example_path(ctx, 'pmemobj', 'mapcli', dirname='map') testfile = os.path.join(ctx.testdir, 'testfile1') arg_fun_dict = { 'hashmap_tx': 'create_hashmap', 'hashmap_atomic': "create_hashmap", 'hashmap_rp': "hashmap_create", 'ctree': 'ctree_map_create', 'btree': 'btree_map_create', 'rtree': 'rtree_map_create', 'rbtree': 'rbtree_map_create', 'skiplist': 'skiplist_map_create' } program_args = ' '.join([ctx.parameters(), testfile]) fun_name = arg_fun_dict.get(ctx.parameters()) self._run_gdb(example_path, program_args, fun_name) ctx.exec(example_path, ctx.parameters(), testfile, std_input=self.input)
def run(self, ctx): example_path = futils.get_example_path(ctx, 'pmemset', 'basic') file_path = ctx.create_non_zero_file(self.file_size, 'testfile0') ctx.exec(example_path, file_path)
def run(self, ctx): example_path = futils.get_example_path(ctx, 'pmem2', 'ringbuf') file_path = ctx.create_holey_file(self.file_size, 'testfile0') ctx.exec(example_path, file_path, 10000, 4096, stdout_file='out6.log')
def run(self, ctx): example_path = futils.get_example_path(ctx, 'pmem2', 'unsafe_shutdown') file_path = ctx.create_holey_file(self.file_size, 'testfile0') ctx.exec(example_path, "write", file_path, "foobar") ctx.exec(example_path, "read", file_path, stdout_file='out5.log')
def run(self, ctx): example_path = futils.get_example_path(ctx, 'pmem2', 'advanced') file_path = ctx.create_non_zero_file(self.file_size, 'testfile0') ctx.exec(example_path, file_path, self.offset, self.length)