def test_1():
    g = Gitana(CONFIG)
    g.delete_previous_logs()
    g.init_db("bootstrap_db_test")
    g.create_project("bootstrap_db_test", "bootstrap")
    g.import_slack_data("bootstrap_db_test", "bootstrap", "slack_bootstrap", SLACK_TOKENS,
                        before_date="2016-08-12", channels=["random", "metascience", "softwareanalysis"])
예제 #2
0
def _cesiumjs():

    TARGETS = [
        "origin/master", "1.0", "1.1", "1.2", "1.3", "1.4", "1.5", "1.6",
        "1.7", "1.8", "1.9", "1.10", "1.11", "1.12", "1.13", "1.14", "1.15",
        "1.16", "1.17", "1.18", "1.19", "1.20", "1.21", "1.22", "1.23", "1.24",
        "1.25", "1.26", "1.27", "1.28", "1.29", "1.30", "1.31", "1.32", "1.33",
        "1.34"
    ]

    g = Gitana(CONFIG, None)
    g.delete_previous_logs()
    # g.init_db("db_cesium")
    # g.create_project("db_cesium", "cesium")
    # print "import git data"
    # g.import_git_data("db_cesium", "cesium", "repo_cesium", "C:\\Users\\atlanmod\\Desktop\\oss\\ants-work\\github-repos\\cesium", references=TARGETS, processes=20)
    # print "import issue tracker"
    # g.import_github_issue_data("db_cesium", "cesium", "repo_cesium", "cesium_it", "AnalyticalGraphicsInc/cesium", GH_TOKENS)
    # g.import_github_pull_request_data("db_cesium", "cesium", "repo_cesium", "cesium_it", "AnalyticalGraphicsInc/cesium", GH_TOKENS)
    # g.match_vcs_and_github_users("db_cesium", "cesium", "repo_cesium", "AnalyticalGraphicsInc/cesium", GH_TOKENS)
    print "import fun data"
    g.import_code_data(
        "db_cesium",
        "cesium",
        "repo_cesium",
        "C:\\Users\\atlanmod\\Desktop\\oss\\ants-work\\github-repos\\cesium",
        references=["origin/master"],
        processes=20)
def test_2():
    # test update
    g = Gitana(CONFIG)
    g.delete_previous_logs()

    g.update_stackoverflow_data("so_db_test", "papyrus",
                                "papyrus-stackoverflow", SO_TOKENS)
예제 #4
0
def _papyrus():
    g = Gitana(CONFIG, None)
    g.delete_previous_logs()
    g.init_db("db_papyrus")
    g.create_project("db_papyrus", "papyrus")
    #print "import git data"
    #g.import_git_data("db_papyrus", "papyrus", "papyrus_repo", "C:\\Users\\atlanmod\\Desktop\\eclipse-git-projects\\papyrus", processes=20)
    print "import bugzilla data"
    g.import_bugzilla_issue_data("_papyrus_db",
                                 "papyrus",
                                 "papyrus_repo",
                                 "bugzilla-papyrus",
                                 "https://bugs.eclipse.org/bugs/xmlrpc.cgi",
                                 "papyrus",
                                 processes=10)
    print "import eclipse forum data"
    g.import_eclipse_forum_data(
        "_papyrus_db",
        "papyrus",
        "papyrus-eclipse",
        "https://www.eclipse.org/forums/index.php/f/121/",
        processes=4)
    print "import stackoverflow data"
    g.import_stackoverflow_data("_papyrus_db", "papyrus",
                                "papyrus-stackoverflow", "papyrus",
                                ['IFco1Gh5EJ*U)ZY5)16ZKQ(('])
예제 #5
0
def _papyrus():
    g = Gitana(CONFIG, None)
    g.delete_previous_logs()
    g.init_db("db_papyrus")
    g.create_project("db_papyrus", "papyrus")
    print("import git data")
    g.import_git_data(
        "db_papyrus",
        "papyrus",
        "papyrus_repo",
        "C:\\Users\\atlanmod\\Desktop\\eclipse-git-projects\\papyrus",
        references=["0.7.0", "0.8.0", "0.9.0", "0.10.0", "1.0.0", "2.0.0"],
        import_type=2,
        processes=20)
    print("import bugzilla data")
    g.import_bugzilla_issue_data("db_papyrus",
                                 "papyrus",
                                 "papyrus_repo",
                                 "bugzilla-papyrus",
                                 "https://bugs.eclipse.org/bugs/xmlrpc.cgi",
                                 "papyrus",
                                 processes=10)
    print("import eclipse forum data")
    g.import_eclipse_forum_data(
        "db_papyrus",
        "papyrus",
        "papyrus-eclipse",
        "https://www.eclipse.org/forums/index.php/f/121/",
        processes=2)
    print("import stackoverflow data")
    g.import_stackoverflow_data("db_papyrus", "papyrus",
                                "papyrus-stackoverflow", "papyrus", SO_TOKENS)
예제 #6
0
def _get_data(db_name, project_name, repo_name, issue_tracker_name, repo_path,
              github_name):
    g = Gitana(CONFIG, None)
    g.delete_previous_logs()
    g.init_db(db_name)
    g.create_project(db_name, project_name)
    print "import git data"
    g.import_git_data(
        db_name,
        project_name,
        repo_name,
        repo_path,
        references=["origin/master"]
    )  #, "v1.0.0", "v1.1.0", "v1.2.0", "v1.3.0", "v1.4.0", "v2.0.0", "v2.1.0", "v2.2.0", "v2.3.0", "v.3.0.0", "v.3.1.0", "v.3.2.0", "v.3.3.0"])
    print "import issue tracker"
    g.import_github_issue_data(db_name, project_name, repo_name,
                               issue_tracker_name, github_name, GH_TOKENS)
    g.import_github_pull_request_data(db_name, project_name, repo_name,
                                      issue_tracker_name, github_name,
                                      GH_TOKENS)
    g.match_vcs_and_github_users(db_name, project_name, repo_name, github_name,
                                 GH_TOKENS)
    print "import fun data"
    g.import_code_data(db_name,
                       project_name,
                       repo_name,
                       repo_path,
                       references=["origin/master"],
                       processes=5)
예제 #7
0
def test_1():
    #test simple
    g = Gitana(CONFIG)
    g.delete_previous_logs()
    g.init_db("so_db_test")
    g.create_project("so_db_test", "papyrus")
    g.import_stackoverflow_data("so_db_test", "papyrus", "papyrus-stackoverflow", "papyrus", SO_TOKENS, before_date="2014-09-01")
def test_1():
    print("test import type 1")

    g = Gitana(CONFIG)
    g.delete_previous_logs()
    g.init_db("vcs1_db_test")
    g.create_project("vcs1_db_test", "2048")
    # test import type 1
    g.import_git_data("vcs1_db_test", "2048", "2048_repo", "C:\\Users\\atlanmod\\Desktop\\2048",
                      import_type=1, processes=5)
def test_4():
    print("test import references")

    g = Gitana(CONFIG)
    g.delete_previous_logs()
    g.init_db("vcs4_db_test")
    g.create_project("vcs4_db_test", "2048")

    # import references
    g.import_git_data("vcs4_db_test", "2048", "2048_repo", "C:\\Users\\atlanmod\\Desktop\\2048",
                      import_type=3, references=REFERENCES, processes=5)
예제 #10
0
def test_1():
    g = Gitana(CONFIG, None)
    g.delete_previous_logs()
    g.init_db("db_2048")
    g.create_project("db_2048", "2048")
    print "import git data"
    g.import_git_data(
        "db_2048", "2048", "repo_2048",
        "C:\\Users\\atlanmod\\Desktop\\oss\\ants-work\\github-repos\\2048")
    print "import code function data"
    g.import_function_data(
        "db_2048", "2048", "repo_2048",
        "C:\\Users\\atlanmod\\Desktop\\oss\\ants-work\\github-repos\\2048")
예제 #11
0
def _file_util_test():
    g = Gitana(CONFIG)
    g.delete_previous_logs()
    h = g.get_file_history("db_2048",
                           "repo_2048",
                           "readme.md",
                           "origin/master",
                           reversed=False,
                           before_date="2014-03-19")
    v = g.get_file_version("db_2048", "repo_2048", "readme.md",
                           "origin/master")

    print "here"
예제 #12
0
def main():
    g = Gitana(CONFIG)
    g.delete_previous_logs()
    g.init_db("bugzilla_db_test")
    g.create_project("bugzilla_db_test", "papyrus")
    g.create_repository("bugzilla_db_test", "papyrus", "papyrus_repo")

    print "starting 1.."
    test_1(g)
    print "starting 2.."
    test_2(g)
    print "starting 3.."
    test_3(g)
def test_5():
    print("test update")

    g = Gitana(CONFIG)
    g.delete_previous_logs()
    g.init_db("vcs5_db_test")
    g.create_project("vcs5_db_test", "2048")

    # import references
    g.import_git_data("vcs5_db_test", "2048", "2048_repo", "C:\\Users\\atlanmod\\Desktop\\2048",
                      before_date="2015-10-10", import_type=2, references=REFERENCES, processes=5)

    # test update
    g.update_git_data("vcs5_db_test", "2048", "2048_repo", "C:\\Users\\atlanmod\\Desktop\\2048")
예제 #14
0
def main():
    g = Gitana(CONFIG)
    g.delete_previous_logs()
    g.init_db("papyrus_db_test")
    g.create_project("papyrus_db_test", "papyrus")

    print "starting 1.."
    test_1(g)
    print "starting 2.."
    test_2(g)
    print "starting 3.."
    test_3(g)
    print "starting 4.."
    test_4(g)
예제 #15
0
def _2048():
    g = Gitana(CONFIG, None)
    g.delete_previous_logs()
    g.init_db("db_2048")
    g.create_project("db_2048", "2048")
    print "import git data"
    g.import_git_data(
        "db_2048",
        "2048",
        "repo_2048",
        "C:\\Users\\atlanmod\\Desktop\\oss\\ants-work\\github-repos\\2048",
        import_type=2)
    print "import github data"
    g.import_github_issue_data("db_2048", "2048", "repo_2048", "2048_it",
                               "gabrielecirulli/2048", GH_TOKENS)
예제 #16
0
def test_3():
    print "test import type 3"

    g = Gitana(CONFIG)
    g.delete_previous_logs()
    g.init_db("db_2048")
    g.create_project("db_2048", "2048")

    #test import type 2
    g.import_git_data("db_2048",
                      "2048",
                      "2048_repo",
                      "C:\\Users\\atlanmod\\Desktop\\2048",
                      import_type=3,
                      processes=5)
예제 #17
0
def main():
    g = Gitana(CONFIG)
    g.delete_previous_logs()
    g.init_db("vcf_audit_db")

    g.create_project("vcf_audit_db", "vcf_audit")
    g.extract_dependency_relations(
        "vcf_audit_db",
        "vcf_audit",
        "vcf_audit_repo",
        "C:\\mmopuru\\vcf-audit",
        extra_paths=[
            "C:\\mmopuru\\vcf-audit\\vcf-audit-compliance\\src\\main\\java",
            "C:\\mmopuru\\vcf-audit\\vcf-common-operations\\src\\main\\java",
            "C:\\mmopuru\\vcf-audit\\support\\gobuild"
        ])
예제 #18
0
def _decidim():
    g = Gitana(CONFIG, None)
    g.delete_previous_logs()
    g.init_db("db_decidim")
    g.create_project("db_decidim", "decidim")
    print "import git data"
    g.import_git_data(
        "db_decidim",
        "decidim",
        "repo_decidim",
        "C:\\Users\\atlanmod\\Desktop\\decidim-analysis\\decidim",
        references=["origin/master"])
    g.match_vcs_and_github_users("db_decidim", "decidim", "repo_decidim",
                                 "decidim/decidim", GH_TOKENS)
    g.export_json("db_decidim",
                  "repo_decidim",
                  "./decidim-master.json",
                  references=["origin/master"])
예제 #19
0
def main():
    g = Gitana(CONFIG)
    g.delete_previous_logs()
    g.init_db("papyrus_db_testx")
    g.create_project("papyrus_db_testx", "papyrus")
    g.import_git_data(
        "papyrus_db_testx",
        "papyrus",
        "papyrus_repo",
        "C:\\Users\\atlanmod\\Desktop\\eclipse-git-projects\\papyrus",
        references=REFERENCES,
        processes=20)

    print("starting 1..")
    test_1(g)
    print("starting 2..")
    test_2(g)
    print("starting 3..")
    test_3(g)
예제 #20
0
def main():
    g = Gitana(CONFIG)
    g.delete_previous_logs()

    print "starting .."
    test(g)
예제 #21
0
def test_add_repository():
    g = Gitana(CONFIG)
    g.delete_previous_logs()
    g.create_repository("dbschema_test", "1", "11")
예제 #22
0
def test_add_user_alias():
    g = Gitana(CONFIG)
    g.delete_previous_logs()
    #g.join_user_identity("db_2048", "TimPetricola", "*****@*****.**", "leereilly", "*****@*****.**")
    g.match_user_identity("db_2048", "gabrielecirulli", None,
                          "Gabriele Cirulli", "*****@*****.**")
def test_2():
    g = Gitana(CONFIG)
    g.delete_previous_logs()

    g.update_slack_data("bootstrap_db_test", "bootstrap", "slack_bootstrap", SLACK_TOKENS)