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
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