def test_create_worklock_agent(testerchain, test_registry, agency,
                               token_economics):
    agent = WorkLockAgent(registry=test_registry)
    assert agent.contract_address
    same_agent = ContractAgency.get_agent(WorkLockAgent,
                                          registry=test_registry)
    assert agent == same_agent
    assert not agent.is_claiming_available()
Beispiel #2
0
def test_make_agent(worklock_deployer, test_registry):

    agent = worklock_deployer.make_agent()

    # Retrieve the PolicyManagerAgent singleton
    another_worklock_agent = WorkLockAgent(registry=test_registry)
    assert agent == another_worklock_agent  # __eq__

    # Compare the contract address for equality
    assert agent.contract_address == another_worklock_agent.contract_address