Skip to content
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

Config test backfill #697

Merged
merged 6 commits into from
Jan 13, 2023
Merged

Conversation

dsabeti
Copy link
Contributor

@dsabeti dsabeti commented Jan 10, 2023

What is this change about?

As we were working on adding a new test suite, we found that there were some inconsistencies in the CATs Config tests. These commits attempt to address the following issues:

  • De-duping struct definitions by embedding structs rather than duplicating values
  • Rename the allConfig test object to nullConfig because it exists specifically to test null values in the config json.
    • We considered trying to write a test to ensure that the nullConfig struct always matches the Config struct to prevent this divergence from occurring again in the future. We decided it was out of scope for what we were hoping to achieve today.
  • Added assertions for untested null value conditions
  • Added assertions for overriding include_* config parameters as these were previously untested
  • Added assertions for default config values for missing include_* config parameters

What version of cf-deployment have you run this cf-acceptance-test change against?

N/A (config test only)

Please check all that apply for this PR:

  • introduces a new test --- Are you sure everyone should be running this test?
  • changes an existing test
  • requires an update to a CATs integration-config

Did you update the README as appropriate for this change?

  • YES
  • N/A

If you are introducing a new acceptance test, what is your rationale for including it CATs rather than your own acceptance test suite?

N/A

How many more (or fewer) seconds of runtime will this change introduce to CATs?

N/A

What is the level of urgency for publishing this change?

  • Urgent - unblocks current or future work
  • Slightly Less than Urgent

Tag your pair, your PM, and/or team!

@aramprice

dsabeti and others added 5 commits January 9, 2023 23:16
Signed-off-by: Aram Price <pricear@vmware.com>
Signed-off-by: David Sabeti <sabetid@vmware.com>
Signed-off-by: Aram Price <pricear@vmware.com>
Signed-off-by: David Sabeti <sabetid@vmware.com>
Signed-off-by: Aram Price <pricear@vmware.com>
@dsabeti
Copy link
Contributor Author

dsabeti commented Jan 10, 2023

@ctlong Just a quick note on merging this: I'd recommend not squashing these commits when you get to merging this. The change is simple, but verbose, and I think it would be hard to follow if all the changes came through in a single commit.

Copy link
Member

@ctlong ctlong left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dsabeti @aramprice just one small comment. Otherwise it all LGTM!

Thanks!

helpers/config/config_struct.go Show resolved Hide resolved
@ctlong ctlong merged commit 7858cd3 into cloudfoundry:develop Jan 13, 2023
@dsabeti dsabeti deleted the config-test-backfill branch January 18, 2023 00:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Development

Successfully merging this pull request may close these issues.

3 participants