bugged stringlengths 4 228k | fixed stringlengths 0 96.3M | __index_level_0__ int64 0 481k |
|---|---|---|
def guess_fontinfo (filename): fi = { 'FontName' : filename, 'FamilyName' : filename, "Weight" : 'regular', "ItalicAngle" : 0, 'FullName' : filename} if re.search ('^cm', filename): fi.update (cm_guess_font_info (filename)) return fi global afmfile if not afmfile: afmfile = find_file (filename + '.afm') if afmfil... | def guess_fontinfo (filename): fi = { 'FontName' : filename, 'FamilyName' : filename, "Weight" : 'regular', "ItalicAngle" : 0, 'FullName' : filename} if re.search ('^cm', filename): fi.update (cm_guess_font_info (filename)) return fi global afmfile if not afmfile: afmfile = find_file (filename + '.afm') if afmfil... | 36,600 |
def guess_fontinfo (filename): fi = { 'FontName' : filename, 'FamilyName' : filename, "Weight" : 'regular', "ItalicAngle" : 0, 'FullName' : filename} if re.search ('^cm', filename): fi.update (cm_guess_font_info (filename)) return fi global afmfile if not afmfile: afmfile = find_file (filename + '.afm') if afmfil... | def guess_fontinfo (filename): fi = { 'FontName' : filename, 'FamilyName' : filename, "Weight" : 'regular', "ItalicAngle" : 0, 'FullName' : filename} if re.search ('^cm', filename): fi.update (cm_guess_font_info (filename)) return fi global afmfile if not afmfile: afmfile = find_file (filename + '.afm') if afmfil... | 36,601 |
def guess_fontinfo (filename): fi = { 'FontName' : filename, 'FamilyName' : filename, "Weight" : 'regular', "ItalicAngle" : 0, 'FullName' : filename} if re.search ('^cm', filename): fi.update (cm_guess_font_info (filename)) return fi global afmfile if not afmfile: afmfile = find_file (filename + '.afm') if afmfil... | def guess_fontinfo (filename): fi = { 'FontName' : filename, 'FamilyName' : filename, "Weight" : 'regular', "ItalicAngle" : 0, 'FullName' : filename} if re.search ('^cm', filename): fi.update (cm_guess_font_info (filename)) return fi global afmfile if not afmfile: afmfile = find_file (filename + '.afm') if afmfil... | 36,602 |
def guess_fontinfo (filename): fi = { 'FontName' : filename, 'FamilyName' : filename, "Weight" : 'regular', "ItalicAngle" : 0, 'FullName' : filename} if re.search ('^cm', filename): fi.update (cm_guess_font_info (filename)) return fi global afmfile if not afmfile: afmfile = find_file (filename + '.afm') if afmfil... | def guess_fontinfo (filename): fi = { 'FontName' : filename, 'FamilyName' : filename, "Weight" : 'regular', "ItalicAngle" : 0, 'FullName' : filename} if re.search ('^cm', filename): fi.update (cm_guess_font_info (filename)) return fi global afmfile if not afmfile: afmfile = find_file (filename + '.afm') if afmfil... | 36,603 |
def guess_fontinfo (filename): fi = { 'FontName' : filename, 'FamilyName' : filename, "Weight" : 'regular', "ItalicAngle" : 0, 'FullName' : filename} if re.search ('^cm', filename): fi.update (cm_guess_font_info (filename)) return fi global afmfile if not afmfile: afmfile = find_file (filename + '.afm') if afmfil... | defguess_fontinfo(filename):fi={'FontName':filename,'FamilyName':filename,"Weight":'regular',"ItalicAngle":0,'FullName':filename}ifre.search('^cm',filename):fi.update(cm_guess_font_info(filename))returnfiglobalafmfileifnotafmfile:afmfile=find_file(filename+'.afm')ifafmfile:afmfile=os.path.abspath(afmfile)afm_struct=afm... | 36,604 |
def guess_fontinfo (filename): fi = { 'FontName' : filename, 'FamilyName' : filename, "Weight" : 'regular', "ItalicAngle" : 0, 'FullName' : filename} if re.search ('^cm', filename): fi.update (cm_guess_font_info (filename)) return fi global afmfile if not afmfile: afmfile = find_file (filename + '.afm') if afmfil... | def guess_fontinfo (filename): fi = { 'FontName' : filename, 'FamilyName' : filename, "Weight" : 'regular', "ItalicAngle" : 0, 'FullName' : filename} if re.search ('^cm', filename): fi.update (cm_guess_font_info (filename)) return fi global afmfile if not afmfile: afmfile = find_file (filename + '.afm') if afmfil... | 36,605 |
def optimal_graphs(target_type, source_groups, generators): """A 'simple generator' that produces the sequence of least-cost solutions for producing the target type from a subset of the source_groups, using the given generators. """ # An index from target type to lists of groups with that type. all_groups = {} # Prime... | def optimal_graphs(target_type, source_groups, generators): """A 'simple generator' that produces the sequence of least-cost solutions for producing the target type from a subset of the source_groups, using the given generators. """ # An index from target type to lists of groups with that type. all_groups = {} # Prime... | 36,606 |
def fail_test(self, condition, *args): | def fail_test(self, condition, *args): | 36,607 |
def read(self, name): return open(self.native_file_name(name), "r").read() | def read(self, name): return open(self.native_file_name(name), "r").read() | 36,608 |
def read_and_strip(self, name): lines = open(self.native_file_name(name), "r").readlines() result = string.join(map(string.rstrip, lines), "\n") if lines and lines[-1][-1] == '\n': return result + '\n' else: return result | def read_and_strip(self, name): lines = open(self.native_file_name(name), "rb").readlines() result = string.join(map(string.rstrip, lines), "\n") if lines and lines[-1][-1] == '\n': return result + '\n' else: return result | 36,609 |
def prepare_suffix_map(toolset): global windows, suffixes suffixes = {'.exe': '', '.dll': '.so', '.lib': '.a', '.obj': '.o'} if os.environ.get('OS','').lower().startswith('windows'): windows = 1 suffixes = {} if toolset in ["gcc"]: suffixes['.lib'] = '.a' # static libs have '.a' suffix with mingw... suffixes['.obj'] = ... | def prepare_suffix_map(toolset): global windows, suffixes suffixes = {'.exe': '', '.dll': '.so', '.lib': '.a', '.obj': '.o'} if os.environ.get('OS','').lower().startswith('windows'): windows = 1 suffixes = {} if toolset in ["gcc"]: suffixes['.lib'] = '.a' # static libs have '.a' suffix with mingw... suffixes['.obj'] = ... | 36,610 |
def __init__(self, arguments="", executable = 'bjam', match = TestCmd.match_exact, boost_build_path = None, translate_suffixes = 1, pass_toolset = 1, **keywords): | def __init__(self, arguments="", executable = 'bjam', match = TestCmd.match_exact, boost_build_path = None, translate_suffixes = 1, pass_toolset = 1, **keywords): | 36,611 |
def __init__(self, arguments="", executable = 'bjam', match = TestCmd.match_exact, boost_build_path = None, translate_suffixes = 1, pass_toolset = 1, **keywords): | def __init__(self, arguments="", executable = 'bjam', match = TestCmd.match_exact, boost_build_path = None, translate_suffixes = 1, pass_toolset = 1, **keywords): | 36,612 |
def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, pass_toolset = None, **kw): | def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, pass_toolset = None, **kw): | 36,613 |
def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, pass_toolset = None, **kw): | def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, pass_toolset = None, **kw): | 36,614 |
def expect_touch(self, names): d = self.unexpected_difference for name in self.adjust_names(names): | def expect_touch(self, names): d = self.unexpected_difference for name in self.adjust_names(names): | 36,615 |
def expect_touch(self, names): d = self.unexpected_difference for name in self.adjust_names(names): | def expect_touch(self, names): d = self.unexpected_difference for name in self.adjust_names(names): | 36,616 |
def reorder_tests(tests, first_test): try: n = tests.index(first_test) return [first_test] + tests[:n] + tests[n+1:] except ValueError: return tests | def reorder_tests(tests, first_test): try: n = tests.index(first_test) return [first_test] + tests[:n] + tests[n+1:] except ValueError: return tests | 36,617 |
def reorder_tests(tests, first_test): try: n = tests.index(first_test) return [first_test] + tests[:n] + tests[n+1:] except ValueError: return tests | def reorder_tests(tests, first_test): try: n = tests.index(first_test) return [first_test] + tests[:n] + tests[n+1:] except ValueError: return tests | 36,618 |
def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, **kw): | def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, **kw): | 36,619 |
def wait_for_time_change(self): while int(time.time()) == self.last_build_time: os.sleep(0.1) | def wait_for_time_change(self): while int(time.time()) == self.last_build_time: os.sleep(0.1) | 36,620 |
def prepare_suffix_map(toolset): suffixes = {'.exe': '', '.dll': '.so', '.lib': '.a', '.obj': '.o'} if os.environ.get('OS','').lower().startswith('windows'): global windows, suffixes windows = 1 suffixes = {} if toolset in ["gcc"]: suffixes['.lib'] = '.a' # static libs have '.a' suffix with mingw... suffixes['.obj'] = ... | def prepare_suffix_map(toolset): suffixes = {'.exe': '', '.dll': '.so', '.lib': '.a', '.obj': '.o'} if os.environ.get('OS','').lower().startswith('windows'): windows = 1 suffixes = {} if toolset in ["gcc"]: suffixes['.lib'] = '.a' # static libs have '.a' suffix with mingw... suffixes['.obj'] = '.o' | 36,621 |
def __init__(self, arguments="", executable = 'bjam', match = TestCmd.match_exact, boost_build_path = None, translate_suffixes = 1, pass_toolset = 1, **keywords): | def __init__(self, arguments="", executable = 'bjam', match = TestCmd.match_exact, boost_build_path = None, translate_suffixes = 1, pass_toolset = 1, **keywords): | 36,622 |
def prepare_suffix_map(toolset): global windows, suffixes suffixes = {'.exe': '', '.dll': '.so', '.lib': '.a', '.obj': '.o'} if os.environ.get('OS','').lower().startswith('windows'): windows = 1 suffixes = {} if toolset in ["gcc"]: suffixes['.lib'] = '.a' # static libs have '.a' suffix with mingw... suffixes['.obj'] = ... | def prepare_suffix_map(toolset): global windows, suffixes suffixes = {'.exe': '', '.dll': '.so', '.lib': '.a', '.obj': '.o'} if os.environ.get('OS','').lower().startswith('windows'): windows = 1 suffixes = {} if toolset in ["gcc"]: suffixes['.lib'] = '.a' # static libs have '.a' suffix with mingw... suffixes['.obj'] = ... | 36,623 |
def __init__(self, arguments="", executable = 'bjam', match = TestCmd.match_exact, boost_build_path = None, translate_suffixes = 1, pass_toolset = 1, **keywords): | def __init__(self, arguments="", executable = 'bjam', match = TestCmd.match_exact, boost_build_path = None, translate_suffixes = 1, pass_toolset = 1, **keywords): | 36,624 |
def __init__(self, arguments="", executable = 'bjam', match = TestCmd.match_exact, boost_build_path = None, translate_suffixes = 1, pass_toolset = 1, **keywords): | def __init__(self, arguments="", executable = 'bjam', match = TestCmd.match_exact, boost_build_path = None, translate_suffixes = 1, pass_toolset = 1, **keywords): | 36,625 |
def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, pass_toolset = None, **kw): | def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, pass_toolset = None, **kw): | 36,626 |
def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, pass_toolset = None, **kw): | def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, pass_toolset = None, **kw): | 36,627 |
def expect_touch(self, names): d = self.unexpected_difference for name in self.adjust_names(names): | def expect_touch(self, names): d = self.unexpected_difference for name in self.adjust_names(names): | 36,628 |
def expect_touch(self, names): d = self.unexpected_difference for name in self.adjust_names(names): | def expect_touch(self, names): d = self.unexpected_difference for name in self.adjust_names(names): | 36,629 |
def __init__(self, arguments="", executable = 'bjam', match = TestCmd.match_exact, boost_build_path = None, translate_suffixes = 1, pass_toolset = 1, **keywords): | def __init__(self, arguments="", executable = 'bjam', match = TestCmd.match_exact, boost_build_path = None, translate_suffixes = 1, pass_toolset = 1, **keywords): | 36,630 |
#ifdef _WIN32 | #ifdef _WIN32 | 36,631 |
def expect_content(self, name, content, exact=0): name = self.adjust_names(name)[0] try: if exact: actual = self.read(name) else: actual = string.replace(self.read_and_strip(name), "\\", "/") except IOError: print "Note: could not open file", name self.fail_test(1) | def expect_content(self, name, content, exact=0): name = self.adjust_names(name)[0] try: if exact: actual = self.read(name) else: actual = string.replace(self.read_and_strip(name), "\\", "/") except IOError: print "Note: could not open file", name self.fail_test(1) | 36,632 |
def reorder_tests(tests, first_test): try: n = tests.index(first_test) return [first_test] + tests[:n] + tests[n+1:] except ValueError: return tests | def reorder_tests(tests, first_test): try: n = tests.index(first_test) return [first_test] + tests[:n] + tests[n+1:] except ValueError: return tests | 36,633 |
#ifdef _WIN32 | #ifdef _WIN32 | 36,634 |
def reorder_tests(tests, first_test): try: n = tests.index(first_test) return [first_test] + tests[:n] + tests[n+1:] except ValueError: return tests | def reorder_tests(tests, first_test): try: n = tests.index(first_test) return [first_test] + tests[:n] + tests[n+1:] except ValueError: return tests | 36,635 |
#ifdef _WIN32 | #ifdef _WIN32 | 36,636 |
#ifdef _WIN32 | #ifdef_WIN32 | 36,637 |
#ifdef _WIN32 | #ifdef _WIN32 | 36,638 |
def __init__(self, arguments="", executable = 'bjam', match = TestCmd.match_exact, boost_build_path = None, translate_suffixes = 1, pass_toolset = 1, **keywords): | def __init__(self, arguments="", executable = 'bjam', match = TestCmd.match_exact, boost_build_path = None, translate_suffixes = 1, pass_toolset = 1, **keywords): | 36,639 |
def fail_test(self, *args, **kw): self.difference.pprint() TestCmd.fail_test(self, *args, **kw) | def fail_test(self, *args, **kw): if hasattr(self, 'difference'): self.difference.pprint() TestCmd.fail_test(self, *args, **kw) | 36,640 |
def run_build_system(self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, **kw): self.previous_tree = build_tree(self.workdir) | def run_build_system(self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, **kw): self.previous_tree = build_tree(self.workdir) | 36,641 |
def run_build_system(self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, **kw): self.previous_tree = build_tree(self.workdir) | def run_build_system(self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, **kw): self.previous_tree = build_tree(self.workdir) | 36,642 |
def run_build_system(self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, **kw): self.previous_tree = build_tree(self.workdir) | def run_build_system(self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, **kw): self.previous_tree = build_tree(self.workdir) | 36,643 |
def rm(self, names): self.wait_for_time_change() if not type(names) == types.ListType: names = [names] | def rm(self, names): self.wait_for_time_change() if not type(names) == types.ListType: names = [names] | 36,644 |
#ifdef _WIN32 | #ifdef _WIN32 | 36,645 |
def __init__(self, arguments="", executable = 'bjam', match = TestCmd.match_exact, boost_build_path = None, translate_suffixes = 1, pass_toolset = 1, **keywords): | def __init__(self, arguments="", executable = 'bjam', match = TestCmd.match_exact, boost_build_path = None, translate_suffixes = 1, pass_toolset = 1, **keywords): | 36,646 |
def __init__(self): | def __init__(self): | 36,647 |
def rm(self, names): self.wait_for_time_change() if not type(names) == types.ListType: names = [names] | def rm(self, names): self.wait_for_time_change() if not type(names) == types.ListType: names = [names] | 36,648 |
def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, pass_toolset = None, **kw): | def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, pass_toolset = None, **kw): | 36,649 |
def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, pass_toolset = None, **kw): | def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, pass_toolset = None, **kw): | 36,650 |
def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, pass_toolset = None, **kw): | def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, pass_toolset = None, **kw): | 36,651 |
def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, pass_toolset = None, **kw): | def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, pass_toolset = None, **kw): | 36,652 |
def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, pass_toolset = None, **kw): | def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, pass_toolset = None, **kw): | 36,653 |
def fail_test(self, condition, *args): | def fail_test(self, condition, *args): | 36,654 |
def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, **kw): | def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, **kw): | 36,655 |
def read_and_strip(self, name): lines = open(self.native_file_name(name), "r").readlines() result = string.join(map(string.rstrip, lines), "\n") if lines and lines[-1][-1] == '\n': return result + '\n' else: return result | defdef fail_test(self, *args, **kw): self.difference.pprint() TestCmd.fail_test(self, *args, **kw) read_and_strip(self,def fail_test(self, *args, **kw): self.difference.pprint() TestCmd.fail_test(self, *args, **kw) name):def fail_test(self, *args, **kw): self.difference.pprint() TestCmd.fail_test(self, *args, **kw) ... | 36,656 |
def _examine_edge(states, queue, g): """Handle a possible new state in the search. """ g_state = State(g) v = states.setdefault(g_state, g_state) if v.group is g: queue.append(g_state) return False if v.group.cost > g.cost: if debug: print 'reducing cost of state(%s) via %s' % (v.group,g) v.group.ambiguous = None v.g... | def _examine_edge(states, queue, g): """Handle a possible new state in the search. """ g_state = State(g) v = states.setdefault(g_state, g_state) if v.group is g: queue.append(g_state) return False if v.group.cost > g.cost: if debug: print 'reducing cost of state(%s) via %s' % (v.group,g) v.group.ambiguous = None v.g... | 36,657 |
def __init__(self, s=""): # Have to handle espaced spaces correctly s = string.replace(s, "\ ", '\001') self.l = [] for e in string.split(s): self.l.append(string.replace(e, '\001', ' ')) | def __init__(self, s=""): # Have to handle espaced spaces correctlyelements = [] if isinstance(s, type("")): s = string.replace(s, "\ ", '\001') elements = string.split(s) else: elements = s; self.l = [] for e in elements: self.l.append(string.replace(e, '\001', ' ')) | 36,658 |
def __delitem__(self, key): del self.l[key] | def __delitem__(self, key): del self.l[key] | 36,659 |
def __mul__(self, other): result = List() for f in self: for s in other: result.l.append(f + s) return result | def __mul__(self, other): result = List() for f in self: for s in other: result.l.append(f + s) return result | 36,660 |
def reorder_tests(tests, first_test): try: n = tests.index(first_test) return [first_test] + tests[:n] + tests[n+1:] except ValueError: return tests | def reorder_tests(tests, first_test): try: n = tests.index(first_test) return [first_test] + tests[:n] + tests[n+1:] except ValueError: return tests | 36,661 |
#ifdef _WIN32 | #ifdef _WIN32 | 36,662 |
#ifdef _WIN32 | #ifdef _WIN32 | 36,663 |
#ifdef _WIN32 | #ifdef _WIN32 | 36,664 |
def reorder_tests(tests, first_test): try: n = tests.index(first_test) return [first_test] + tests[:n] + tests[n+1:] except ValueError: return tests | def reorder_tests(tests, first_test): try: n = tests.index(first_test) return [first_test] + tests[:n] + tests[n+1:] except ValueError: return tests | 36,665 |
def __init__( self , target_type , size # how many of that type are in the group. , parents = () , generator = None): """ >>> g1 = TargetTypeGroup('x', 1) >>> assert not g1.extra_targets >>> assert g1.consumed_sources == { g1:1 } >>> g2 = TargetTypeGroup('x', 1) >>> g3 = TargetTypeGroup('x', 1, [g1,g2]) >>> asse... | def __init__( self , target_type , size # how many of that type are in the group. , parents = () , generator = None): """ >>> g1 = TargetTypeGroup('x', 1) >>> assert not g1.extra_targets >>> assert g1.consumed_sources == { g1:1 } >>> g2 = TargetTypeGroup('x', 1) >>> g3 = TargetTypeGroup('x', 1, [g1,g2]) >>> asse... | 36,666 |
def __init__( self , target_type , size # how many of that type are in the group. , parents = () , generator = None): """ >>> g1 = TargetTypeGroup('x', 1) >>> assert not g1.extra_targets >>> assert g1.consumed_sources == { g1:1 } >>> g2 = TargetTypeGroup('x', 1) >>> g3 = TargetTypeGroup('x', 1, [g1,g2]) >>> asse... | def __init__( self , target_type , size # how many of that type are in the group. , parents = () , generator = None): """ >>> g1 = TargetTypeGroup('x', 1) >>> assert not g1.extra_targets >>> assert g1.consumed_sources == { g1:1 } >>> g2 = TargetTypeGroup('x', 1) >>> g3 = TargetTypeGroup('x', 1, [g1,g2]) >>> asse... | 36,667 |
def __init__( self , target_type , size # how many of that type are in the group. , parents = () , generator = None): """ >>> g1 = TargetTypeGroup('x', 1) >>> assert not g1.extra_targets >>> assert g1.consumed_sources == { g1:1 } >>> g2 = TargetTypeGroup('x', 1) >>> g3 = TargetTypeGroup('x', 1, [g1,g2]) >>> asse... | def __init__( self , target_type , size # how many of that type are in the group. , parents = () , generator = None): """ >>> g1 = TargetTypeGroup('x', 1) >>> assert not g1.extra_targets >>> assert g1.consumed_sources == { g1:1 } >>> g2 = TargetTypeGroup('x', 1) >>> g3 = TargetTypeGroup('x', 1, [g1,g2]) >>> asse... | 36,668 |
def __init__( self , target_type , size # how many of that type are in the group. , parents = () , generator = None): """ >>> g1 = TargetTypeGroup('x', 1) >>> assert not g1.extra_targets >>> assert g1.consumed_sources == { g1:1 } >>> g2 = TargetTypeGroup('x', 1) >>> g3 = TargetTypeGroup('x', 1, [g1,g2]) >>> asse... | def __init__( self , target_type , size # how many of that type are in the group. , parents = () , generator = None): """ >>> g1 = TargetTypeGroup('x', 1) >>> assert not g1.extra_targets >>> assert g1.consumed_sources == { g1:1 } >>> g2 = TargetTypeGroup('x', 1) >>> g3 = TargetTypeGroup('x', 1, [g1,g2]) >>> asse... | 36,669 |
def __get_constituents(self): if self.__constituents is None: self.__constituents = {self:1} for c in self.parents: self.__constituents.update(c.constituents) return self.__constituents | defcost = property(lambda self: len(self.moves)) __get_constituents(self):cost = property(lambda self: len(self.moves)) ifcost = property(lambda self: len(self.moves)) self.__constituentscost = property(lambda self: len(self.moves)) iscost = property(lambda self: len(self.moves)) None:cost = property(lambda self: ... | 36,670 |
def parent_sets(chosen, signature, all_groups, generator): """Given an already-chosen tuple of TargetTypeGroups and a signature of the groups left to choose, generates all mutually-compatible combinations of groups starting with chosen >>> TargetTypeGroup.instances = 0 >>> groups = { ... 'x': [ TargetTypeGroup('x',... | def parent_sets(chosen, signature, all_groups, generator): """Given an already-chosen tuple of TargetTypeGroups and a signature of the groups left to choose, generates all mutually-compatible combinations of groups starting with chosen >>> TargetTypeGroup.instances = 0 >>> groups = { ... 'x': [ TargetTypeGroup('x',... | 36,671 |
def expect_content(self, name, content, exact=0): name = self.adjust_names(name)[0] try: if exact: actual = self.read(name) else: actual = string.replace(self.read_and_strip(name), "\\", "/") except IOError: print "Note: could not open file", name self.fail_test(1) | def expect_content(self, name, content, exact=0): name = self.adjust_names(name)[0] try: if exact: actual = self.read(name) else: actual = string.replace(self.read_and_strip(name), "\\", "/") except IOError: print "Note: could not open file", name self.fail_test(1) | 36,672 |
def expect_touch(self, names): d = self.unexpected_difference for name in self.adjust_names(names): | def expect_touch(self, names): d = self.unexpected_difference for name in self.adjust_names(names): | 36,673 |
def run_tests(critical_tests, other_tests): """Runs first critical tests and then other_tests. Stops on first error, and write the name of failed test to test_results.txt. Critical tests are run in the specified order, other tests are run starting with the one that failed the last time. """ last_failed = last_failed_t... | def run_tests(critical_tests, other_tests): """Runs first critical tests and then other_tests. Stops on first error, and write the name of failed test to test_results.txt. Critical tests are run in the specified order, other tests are run starting with the one that failed the last time. """ last_failed = last_failed_t... | 36,674 |
def run_tests(critical_tests, other_tests): """Runs first critical tests and then other_tests. Stops on first error, and write the name of failed test to test_results.txt. Critical tests are run in the specified order, other tests are run starting with the one that failed the last time. """ last_failed = last_failed_t... | def run_tests(critical_tests, other_tests): """Runs first critical tests and then other_tests. Stops on first error, and write the name of failed test to test_results.txt. Critical tests are run in the specified order, other tests are run starting with the one that failed the last time. """ last_failed = last_failed_t... | 36,675 |
#ifdef _WIN32 | #ifdef _WIN32 | 36,676 |
#ifdef _WIN32 | #ifdef _WIN32 | 36,677 |
def touch(self, names): self.wait_for_time_change() if not type(names) == types.ListType: names = [names] for name in names: os.utime(self.native_file_name(name), None) | def touch(self, names): self.wait_for_time_change() for name in self.adjust_names(names): os.utime(self.native_file_name(name), None) | 36,678 |
def __init__(self, arguments="", executable = 'bjam', match = TestCmd.match_exact, boost_build_path = None, translate_suffixes = 1, pass_toolset = 1, **keywords): | def __init__(self, arguments="", executable = 'bjam', match = TestCmd.match_exact, boost_build_path = None, translate_suffixes = 1, pass_toolset = 1, **keywords): | 36,679 |
def __init__(self, arguments="", executable = 'bjam', match = TestCmd.match_exact, boost_build_path = None, translate_suffixes = 1, pass_toolset = 1, **keywords): | def __init__(self, arguments="", executable = 'bjam', match = TestCmd.match_exact, boost_build_path = None, translate_suffixes = 1, pass_toolset = 1, **keywords): | 36,680 |
def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, pass_toolset = None, **kw): | def run_build_system( self, extra_args='', subdir='', stdout = None, stderr = '', status = 0, match = None, pass_toolset = None, **kw): | 36,681 |
#ifdef _WIN32 | #ifdef _WIN32 | 36,682 |
#ifdef _WIN32 | #ifdef _WIN32 | 36,683 |
#ifdef _WIN32 | #ifdef _WIN32 | 36,684 |
#ifdef _WIN32 | #ifdef _WIN32 | 36,685 |
def reorder_tests(tests, first_test): try: n = tests.index(first_test) return [first_test] + tests[:n] + tests[n+1:] except ValueError: return tests | def reorder_tests(tests, first_test): try: n = tests.index(first_test) return [first_test] + tests[:n] + tests[n+1:] except ValueError: return tests | 36,686 |
def reorder_tests(tests, first_test): try: n = tests.index(first_test) return [first_test] + tests[:n] + tests[n+1:] except ValueError: return tests | def reorder_tests(tests, first_test): try: n = tests.index(first_test) return [first_test] + tests[:n] + tests[n+1:] except ValueError: return tests | 36,687 |
def ignore_addition(self, wildcard): ignore_elements(self.unexpected_difference.added_files, wildcard) | def ignore_addition(self, wildcard): ignore_elements(self.unexpected_difference.added_files, wildcard) | 36,688 |
def ignore_removal(self, wildcard): ignore_elements(self.unexpected_difference.removed_files, wildcard) | def ignore_removal(self, wildcard): ignore_elements(self.unexpected_difference.removed_files, wildcard) | 36,689 |
def ignore_modification(self, wildcard): ignore_elements(self.unexpected_difference.modified_files, wildcard) | def ignore_modification(self, wildcard): ignore_elements(self.unexpected_difference.modified_files, wildcard) | 36,690 |
def ignore_touch(self, wildcard): ignore_elements(self.unexpected_difference.touched_files, wildcard) | def ignore_touch(self, wildcard): ignore_elements(self.unexpected_difference.touched_files, wildcard) | 36,691 |
def ignore(self, wildcard): ignore_elements(self.unexpected_difference.added_files, wildcard) ignore_elements(self.unexpected_difference.removed_files, wildcard) ignore_elements(self.unexpected_difference.modified_files, wildcard) ignore_elements(self.unexpected_difference.touched_files, wildcard) | def ignore(self, wildcard): ignore_elements(self.unexpected_difference.added_files, wildcard) ignore_elements(self.unexpected_difference.removed_files, wildcard) ignore_elements(self.unexpected_difference.modified_files, wildcard) ignore_elements(self.unexpected_difference.touched_files, wildcard) | 36,692 |
def ignore_elements(list, wildcard): """Removes in-place, element of 'list' that match the given wildcard.""" w = fnmatch.translate(wildcard) list[:] = filter(lambda x, w=w: not w(x), list) | def ignore_elements(self, list, wildcard): """Removes in-place, element of 'list' that match the given wildcard.""" w = fnmatch.translate(wildcard) list[:] = filter(lambda x, w=w: not w(x), list) | 36,693 |
def ignore_elements(list, wildcard): """Removes in-place, element of 'list' that match the given wildcard.""" w = fnmatch.translate(wildcard) list[:] = filter(lambda x, w=w: not w(x), list) | def ignore_elements(list, wildcard): """Removes in-place, element of 'list' that match the given wildcard.""" w = fnmatch.translate(wildcard) list[:] = filter(lambda x, w=w: not w(x), list) | 36,694 |
def __init__(self): | def __init__(self): | 36,695 |
def read(self, name): return open(self.native_file_name(name), "wb").read() | def read(self, name): return open(self.native_file_name(name), "wb").read() | 36,696 |
def empty(): return (len(self.added_files) == 0 and len(self.removed_files) == 0)\ and len(modified_files) == 0 and len(self.touched_files) == 0 | def empty(self): return (len(self.added_files) == 0 and len(self.removed_files) == 0)\ and len(modified_files) == 0 and len(self.touched_files) == 0 | 36,697 |
def run_tests(critical_tests, other_tests): """Runs first critical tests and then other_tests. Stops on first error, and write the name of failed test to test_results.txt. Critical tests are run in the specified order, other tests are run starting with the one that failed the last time. """ last_failed = last_failed_t... | def run_tests(critical_tests, other_tests): """Runs first critical tests and then other_tests. Stops on first error, and write the name of failed test to test_results.txt. Critical tests are run in the specified order, other tests are run starting with the one that failed the last time. """ last_failed = last_failed_t... | 36,698 |
def run_tests(critical_tests, other_tests): """Runs first critical tests and then other_tests. Stops on first error, and write the name of failed test to test_results.txt. Critical tests are run in the specified order, other tests are run starting with the one that failed the last time. """ last_failed = last_failed_t... | def run_tests(critical_tests, other_tests): """Runs first critical tests and then other_tests. Stops on first error, and write the name of failed test to test_results.txt. Critical tests are run in the specified order, other tests are run starting with the one that failed the last time. """ last_failed = last_failed_t... | 36,699 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.