Ejemplo n.º 1
0
def test_parse_intent_path():
    expected = {
        "project": "winkle",
        "intent": "nautilus",
    }
    path = SessionsClient.intent_path(**expected)

    # Check that the path construction is reversible.
    actual = SessionsClient.parse_intent_path(path)
    assert expected == actual
Ejemplo n.º 2
0
def test_intent_path():
    project = "cuttlefish"
    intent = "mussel"

    expected = "projects/{project}/agent/intents/{intent}".format(
        project=project,
        intent=intent,
    )
    actual = SessionsClient.intent_path(project, intent)
    assert expected == actual