-
Notifications
You must be signed in to change notification settings - Fork 13
External URLs configured in the Settings file
A workflow may include actions that call APIs and services using the HTTP connector. It is recommended that the URL for the API or service is stored as a setting in the local.settings.json
file and not hard-coded in the workflow definition - this allows the workflow to be promoted through environments more easily.
The testing framework can be configured to replace the host name in these URLs with a URL for a mock HTTP server that is managed by the testing framework. The host names to be replaced are configured using the workflow.externalApiUrlsToMock
section in the testConfiguration.json
file:
"workflow": {
"externalApiUrlsToMock": [
"https://external-service-one.testing.net",
"https://external-service-two.testing.net"
]
}
So this setting:
"ServiceOne-Url": "https://external-service-one.testing.net/api/v1/employee",
Will be updated to:
"ServiceOne-Url": "https://local-server-name:7075/api/v1/employee",
NOTE: If the API or service URL is hard-coded in a workflow definition, it will not be updated by the testing framework.
- Home
- Using the Testing Framework
- Test Configuration
- Azurite
- Local Settings File
- Test Execution Logs
- Stateless Workflows
- Handling Workflow Dependencies
- Fluent API
- Automated testing using a DevOps pipeline
- Summary of Test Configuration Options
-
Example Mock Requests and Responses
- Call a Local Function action
- Invoke Workflow action
- Built-In Connectors:
- Service Bus
- SMTP
- Storage Account
- SQL Server