Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions ibm_catalog.json
Original file line number Diff line number Diff line change
Expand Up @@ -377,7 +377,7 @@
},
{
"name": "deploy-arch-ibm-cloud-logs",
"description": "Enable this to create an IBM Cloud Logs (ICL) Instance which can be used for storage and analysis of events ingested by Activity Tracker. ",
"description": "Configure IBM Cloud Logs to analyse the platform logs.",
"catalog_id": "7a4d68b4-cf8b-40cd-a3d1-f49aff526eb3",
"flavors": [
"fully-configurable"
Expand Down Expand Up @@ -409,7 +409,7 @@
},
{
"name": "deploy-arch-ibm-cloud-monitoring",
"description": "Enable IBM Cloud Monitoring to gain operational visibility into your cloud storage buckets. ",
"description": "Configure IBM Cloud Monitoring to collect the platform metrics.",
"id": "73debdbf-894f-4c14-81c7-5ece3a70b67d-global",
"version": "v1.6.4",
"flavors": [
Expand Down
2 changes: 1 addition & 1 deletion tests/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ toolchain go1.25.0
require (
github.com/gruntwork-io/terratest v0.50.0
github.com/stretchr/testify v1.11.1
github.com/terraform-ibm-modules/ibmcloud-terratest-wrapper v1.60.1
github.com/terraform-ibm-modules/ibmcloud-terratest-wrapper v1.60.3
)

require (
Expand Down
4 changes: 2 additions & 2 deletions tests/go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -295,8 +295,8 @@ github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO
github.com/stretchr/testify v1.8.2/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4=
github.com/stretchr/testify v1.11.1 h1:7s2iGBzp5EwR7/aIZr8ao5+dra3wiQyKjjFuvgVKu7U=
github.com/stretchr/testify v1.11.1/go.mod h1:wZwfW3scLgRK+23gO65QZefKpKQRnfz6sD981Nm4B6U=
github.com/terraform-ibm-modules/ibmcloud-terratest-wrapper v1.60.1 h1:tcQG5sh+M4CGglqR221muoANVTXD01ZX7rIEURfw4ZM=
github.com/terraform-ibm-modules/ibmcloud-terratest-wrapper v1.60.1/go.mod h1:QQiS4/GrSDsVuI1Jdw8MTLmBJv68QiVfuLpiM+e9rt0=
github.com/terraform-ibm-modules/ibmcloud-terratest-wrapper v1.60.3 h1:eR7/W4+SmqfDfeD33ZVmtKrtM+KtcbAbURfjKAnXyic=
github.com/terraform-ibm-modules/ibmcloud-terratest-wrapper v1.60.3/go.mod h1:9Thq3InVLYHEtKIVABm8e1d7jvpIQqlKCJ8/d5wH6DY=
github.com/tidwall/pretty v1.0.0/go.mod h1:XNkn88O1ChpSDQmQeStsy+sBenx6DDtFZJxhVysOjyk=
github.com/tmccombs/hcl2json v0.6.4 h1:/FWnzS9JCuyZ4MNwrG4vMrFrzRgsWEOVi+1AyYUVLGw=
github.com/tmccombs/hcl2json v0.6.4/go.mod h1:+ppKlIW3H5nsAsZddXPy2iMyvld3SHxyjswOZhavRDk=
Expand Down
47 changes: 47 additions & 0 deletions tests/pr_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@ import (
"github.com/gruntwork-io/terratest/modules/terraform"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
"github.com/terraform-ibm-modules/ibmcloud-terratest-wrapper/cloudinfo"
"github.com/terraform-ibm-modules/ibmcloud-terratest-wrapper/common"
"github.com/terraform-ibm-modules/ibmcloud-terratest-wrapper/testaddons"
"github.com/terraform-ibm-modules/ibmcloud-terratest-wrapper/testhelper"
"github.com/terraform-ibm-modules/ibmcloud-terratest-wrapper/testschematic"
)
Expand Down Expand Up @@ -248,3 +250,48 @@ func TestRunAccountSettings(t *testing.T) {
err := options.RunSchematicTest()
assert.Nil(t, err, "This should not have errored")
}

func TestActivityTrackerDefaultConfiguration(t *testing.T) {
t.Parallel()

options := testaddons.TestAddonsOptionsDefault(&testaddons.TestAddonOptions{
Testing: t,
Prefix: "act-def",
ResourceGroup: resourceGroup,
QuietMode: true, // Suppress logs except on failure
})

options.AddonConfig = cloudinfo.NewAddonConfigTerraform(
options.Prefix,
"deploy-arch-ibm-activity-tracker",
"fully-configurable",
map[string]interface{}{
"prefix": options.Prefix,
"region": validRegions[rand.Intn(len(validRegions))],
},
)

err := options.RunAddonTest()
require.NoError(t, err)
}

func TestActivityTrackerDependencyPermutations(t *testing.T) {
t.Skip("Skipping dependency permutations until the test is fixed")
t.Parallel()
options := testaddons.TestAddonsOptionsDefault(&testaddons.TestAddonOptions{
Testing: t,
Prefix: "act-per",
AddonConfig: cloudinfo.AddonConfig{
OfferingName: "deploy-arch-ibm-activity-tracker",
OfferingFlavor: "fully-configurable",
Inputs: map[string]interface{}{
"prefix": "act-per",
"region": validRegions[rand.Intn(len(validRegions))],
"existing_resource_group_name": resourceGroup,
},
},
})

err := options.RunAddonPermutationTest()
assert.NoError(t, err, "Dependency permutation test should not fail")
}