Exemple #1
0
def test():
    task1 = DMTask()
    val = {"name": "fake-followers", "action_type": "loop", "start": 6001000, "end": 6005000}
    task1.init_test("github", val)
    e1 = GithubFollowers(task1)
    e1.runTask()
    task1.remove()
Exemple #2
0
def test():
    task1 = DMTask()
    val = {"name": "fake-repo", "action_type": "loop", "start": 6001000, "end": 6005000}

    task1.init_test("github", val)
    e1 = GithubRepo(task1)
    e1.runTask()
    task1.remove()
Exemple #3
0
def test():
    db = DMDatabase().getDB()
    res = db["event"].find({"id": {"$gte": 1000, "$lt": 200}}).limit(20)
    if res is None:
        print 'res is none'
    else:
        print res.count()
    return

    task1 = DMTask()
    val = {"name": "fake-event", "action_type": "loop", "start": 6001000, "end": 6005000}

    task1.init_test("github", val)
    e1 = GithubEvent(task1)
    e1.runTask()
    task1.remove()