github.com/swisspost/terratest@v0.0.0-20230214120104-7ec6de2e1ae0/examples/azure/terraform-azure-servicebus-example/README.md (about)

     1  # Terraform Azure Service Bus Example
     2  
     3  This folder contains a Terraform module that deploys resources in [Azure](https://azure.microsoft.com/) to demonstrate how you can use Terratest to write automated tests for your Azure Terraform code. This module deploys a Service Bus.
     4  
     5  - A [Service Bus](https://docs.microsoft.com/en-us/azure/service-bus-messaging/service-bus-messaging-overview) with the namespace specified in the `namespace_name` variable.
     6  
     7  Check out [test/azure/terraform_azure_servicebus_example_test.go](./../../../test/azure/terraform_azure_servicebus_example_test.go) to see how you can write automated tests for this module and validate the configuration of the parameters and options. 
     8  
     9  **WARNING**: This module and the automated tests for it deploy real resources into your Azure account which can cost you money. The resources are all part of the [Azure Free Account](https://azure.microsoft.com/en-us/free/), so if you haven't used that up,
    10  it should be free, but you are completely responsible for all Azure charges.
    11  
    12  ## Running this module manually
    13  1. Sign up for [Azure](https://azure.microsoft.com/).
    14  1. Configure your Azure credentials using one of the [supported methods for Azure CLI
    15     tools](https://docs.microsoft.com/en-us/cli/azure/azure-cli-configuration?view=azure-cli-latest)
    16  1. Install [Terraform](https://www.terraform.io/) and make sure it's on your `PATH`.
    17  1. Ensure [environment variables](../README.md#review-environment-variables) are available
    18  1. Run `terraform init`
    19  1. Run `terraform apply`
    20  1. When you're done, run `terraform destroy`.
    21  
    22  
    23  ## Running automated tests against this module
    24  1. Sign up for [Azure](https://azure.microsoft.com/)
    25  1. Configure your Azure credentials using one of the [supported methods for Azure CLI
    26     tools](https://docs.microsoft.com/en-us/cli/azure/azure-cli-configuration?view=azure-cli-latest)
    27  1. Install [Terraform](https://www.terraform.io/) and make sure it's on your `PATH`
    28  1. Configure your Terratest [Go test environment](../README.md) 
    29  1. `cd test/azure`
    30  1. `go build terraform_azure_servicebus_example_test.go`
    31  1. `go test -v -run TestTerraformAzureServiceBusExample`