def info(args): testsuite_paths = discover_testsuites(args.testsuite_directory or []) if args.select_all: testsuites = load_testsuites(testsuite_paths, testsuite_paths.keys()) else: testsuites = load_testsuites(testsuite_paths, args.select or []) print('version=' + VERSION) testsuites_descr = [] tbp = tests = 0 for name, testsuite in testsuites.items(): bp = 0 for test in testsuite.tests: if isinstance(test.template, genes.DynamicTemplate): bp += len(test.template.seq(spacing=args.spacing)) else: bp += len(test.template.seq()) testsuites_descr.append('%s-%s[%d:%dbp]' % ( name, testsuite.version, len(testsuite.tests), bp)) tbp += bp tests += len(testsuite.tests) print('testsuites=' + ','.join(testsuites_descr)) print('sum=%d tests,%dbp' % (tests, tbp)) print('sys.prefix=' + sys.prefix)
def scan(args): testsuite_paths = discover_testsuites(args.testsuite_directory or []) if args.select_all: testsuites = load_testsuites(testsuite_paths, testsuite_paths.keys()) else: testsuites = load_testsuites(testsuite_paths, args.select) if not testsuites: sys.stderr.write('\n*** you must specify at least one testsuite! ***\n\n') sys.stderr.write('(use the -t command line switch)\n\n') sys.exit(ERROR_COMMAND_LINE_SWITCH) # prepare scanning {{{2 try: fastq = Fastq(args.fastq, paired=not args.no_paired, variant=args.variant) except FastqFileFormatException, e: lo.error('cannot open file %s : %s'%(args.fastq, str(e))) sys.exit(ERROR_FASTQ_FORMAT_ERROR)
def setUpClass(cls): lo.setLevel(logging.WARNING) cls.testsuite_paths = discover_testsuites([testsuites_alt]) cls.testsuites = load_testsuites(cls.testsuite_paths, ['MTBC'])