Skip to content
This repository was archived by the owner on Jul 22, 2025. It is now read-only.

Commit 4895c8c

Browse files
committed
fix test name
1 parent d8e9bc6 commit 4895c8c

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

octopusdeploy_framework/resource_machine_proxy_test.go

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,13 +29,13 @@ func TestAccMachineProxyBasic(t *testing.T) {
2929
ProtoV6ProviderFactories: ProtoV6ProviderFactories(),
3030
Steps: []resource.TestStep{
3131
{
32-
Config: testMachineProxyBasic(data),
32+
Config: testMachineProxyBasic(data, localName),
3333
Check: resource.ComposeTestCheckFunc(
3434
resource.TestCheckResourceAttr(prefix, "name", data.Name),
3535
),
3636
},
3737
{
38-
Config: testMachineProxyUpdate(data),
38+
Config: testMachineProxyUpdate(data, localName),
3939
Check: resource.ComposeTestCheckFunc(
4040
resource.TestCheckResourceAttr(prefix, "name", data.Name+"-updated"),
4141
),
@@ -44,16 +44,17 @@ func TestAccMachineProxyBasic(t *testing.T) {
4444
})
4545
}
4646

47-
func testMachineProxyBasic(data *proxies.Proxy) string {
47+
func testMachineProxyBasic(data *proxies.Proxy, localName string) string {
4848
return fmt.Sprintf(`
49-
resource "octopusdeploy_machine_proxy" "test_proxy" {
49+
resource "octopusdeploy_machine_proxy" "%s" {
5050
name = "%s"
5151
host = "%s"
5252
username = "%s"
5353
password = "%s"
5454
port = %d
5555
}
5656
`,
57+
localName,
5758
data.Name,
5859
data.Host,
5960
data.Username,
@@ -62,10 +63,10 @@ func testMachineProxyBasic(data *proxies.Proxy) string {
6263
)
6364
}
6465

65-
func testMachineProxyUpdate(data *proxies.Proxy) string {
66+
func testMachineProxyUpdate(data *proxies.Proxy, localName string) string {
6667
data.Name = data.Name + "-updated"
6768

68-
return testMachineProxyBasic(data)
69+
return testMachineProxyBasic(data, localName)
6970
}
7071

7172
func testMachineProxyDestroy(s *terraform.State) error {

0 commit comments

Comments
 (0)