def METHOD_NAME(flask_client):
    email = random_email()
    r = flask_client.post(
        url_for("api.auth_register"),
        json={"email": email, "password": "password"},
    )
    assert r.status_code == 200
    assert r.json["msg"]
    # get the activation code
    act_code = AccountActivation.first()
    assert act_code
    assert len(act_code.code) == 6
    r = flask_client.post(
        url_for("api.auth_activate"),
        json={"email": email, "code": act_code.code},
    )
    assert r.status_code == 200