-
Notifications
You must be signed in to change notification settings - Fork 988
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add conditions attribute to kubernetes_nodes data source #2612
Add conditions attribute to kubernetes_nodes data source #2612
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good. Small question around test coverage, otherwise all good.
@@ -33,6 +33,9 @@ func TestAccKubernetesDataSourceNodes_basic(t *testing.T) { | |||
resource.TestCheckResourceAttrWith(dataSourceName, "nodes.0.status.0.capacity.memory", checkParsableQuantity), | |||
resource.TestCheckResourceAttrSet(dataSourceName, "nodes.0.status.0.node_info.0.architecture"), | |||
resource.TestCheckResourceAttrSet(dataSourceName, "nodes.0.status.0.addresses.0.address"), | |||
resource.TestMatchResourceAttr(dataSourceName, "nodes.0.status.0.conditions.#", oneOrMore), | |||
resource.TestCheckResourceAttrSet(dataSourceName, "nodes.0.status.0.conditions.0.type"), | |||
resource.TestCheckResourceAttrSet(dataSourceName, "nodes.0.status.0.conditions.0.status"), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it not feasible to test for all the newly introduced attributes?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can certainly do that! Will update the test, to include the additional attributes 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice one, @JaylonmcShan03
🚀
Description
Fixes #2430
This PR introduces a new
conditions
attribute to thekubernetes_nodes
data source, which will provide detailed insights into each node's health and operational status.Acceptance tests
Output from acceptance testing:
Release Note
Release note for CHANGELOG:
References
Community Note