コード例 #1
0
ファイル: test.py プロジェクト: mrajashree/wolf
    for class_desc in class_desc_list:
        print class_desc.package + '.' + class_desc.name
        package_list += [class_desc.package]
    package_name = os.path.commonprefix(package_list)
    if package_name.endswith('.'):
        package_name = package_name[:-1]
    print "Package Name:" + package_name
    print "\033[92mDone.\033[37m"
    print "***********************************************\n"
    if not args.noPrompts:
        raw_input()

    print "***********************************************"
    print "\033[92mInserting PITest plugin into existing pom.xml..\033[37m"
    pitest_runner = PITest('/'.join([repo_path, 'pom.xml']))
    pitest_runner.insert_into_pom(package_name)
    print "\033[92mDone.\033[37m"
    print "***********************************************\n"
    if not args.noPrompts:
        raw_input()

    print "***********************************************"
    print "\033[92mAssembling the jar with dependencies..\033[37m"
    mvn_runner = MvnRunner(project_path=rh.get_path(), subfolder=args.subfolder,
                           quiet_mode=True)
    # assemble the jar with dependencies
    jar_path = mvn_runner.get_jar_with_deps()
    if jar_path is None:
        mvn_runner.assemble_with_deps()
        jar_path = mvn_runner.get_jar_with_deps()
コード例 #2
0
ファイル: test.py プロジェクト: mrajashree/wolf
for file_desc in rh.get_modified_files(prev_commits=10):

    if repo_path in file_desc.path:
        if (file_desc.ext == ".java"):
            if '/test' not in file_desc.path:
                print 'Adding ' + file_desc.path
                file_name_list += [file_desc.path]
                valid_file_desc += [file_desc]

parser = Parser(file_name_list)
class_desc_list = parser.get_class_descs()
print "Done."

print "Inserting PITest plugin into existing pom.xml.."
pitest_runner = PITest('/'.join([repo_path, 'pom.xml']))
pitest_runner.insert_into_pom('com.rometools')
print "Done."

print "Assembling the jar with dependencies.."
mvn_runner = MvnRunner(repo_path, True)
# assemble the jar with dependencies
jar_path = mvn_runner.get_jar_with_deps()

if jar_path is None:
    mvn_runner.assemble_with_deps()
    jar_path = mvn_runner.get_jar_with_deps()
print "Done."

print "Running PITest for initial analysis.."
mvn_runner.custom('org.pitest:pitest-maven:mutationCoverage')
コード例 #3
0
    for class_desc in class_desc_list:
        print class_desc.package + '.' + class_desc.name
        package_list += [class_desc.package]
    package_name = os.path.commonprefix(package_list)
    if package_name.endswith('.'):
        package_name = package_name[:-1]
    print "Package Name:" + package_name
    print "\033[92mDone.\033[37m"
    print "***********************************************\n"
    if not args.noPrompts:
        raw_input()

    print "***********************************************"
    print "\033[92mInserting PITest plugin into existing pom.xml..\033[37m"
    pitest_runner = PITest('/'.join([repo_path, 'pom.xml']))
    pitest_runner.insert_into_pom(package_name)
    print "\033[92mDone.\033[37m"
    print "***********************************************\n"
    if not args.noPrompts:
        raw_input()

    print "***********************************************"
    print "\033[92mAssembling the jar with dependencies..\033[37m"
    mvn_runner = MvnRunner(project_path=rh.get_path(),
                           subfolder=args.subfolder,
                           quiet_mode=True)
    # assemble the jar with dependencies
    jar_path = mvn_runner.get_jar_with_deps()
    if jar_path is None:
        mvn_runner.assemble_with_deps()
コード例 #4
0
for file_desc in rh.get_modified_files(prev_commits=10):

    if repo_path in file_desc.path:
        if (file_desc.ext == ".java"):
            if '/test' not in file_desc.path:
                print 'Adding ' + file_desc.path
                file_name_list += [file_desc.path]
                valid_file_desc += [file_desc]

parser = Parser(file_name_list)
class_desc_list = parser.get_class_descs()
print "Done."

print "Inserting PITest plugin into existing pom.xml.."
pitest_runner = PITest('/'.join([repo_path, 'pom.xml']))
pitest_runner.insert_into_pom('com.rometools')
print "Done."

print "Assembling the jar with dependencies.."
mvn_runner = MvnRunner(repo_path, True)
# assemble the jar with dependencies
jar_path = mvn_runner.get_jar_with_deps()

if jar_path is None:
    mvn_runner.assemble_with_deps()
    jar_path = mvn_runner.get_jar_with_deps()
print "Done."

print "Running PITest for initial analysis.."
mvn_runner.custom('org.pitest:pitest-maven:mutationCoverage')