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

Add functional tests for ClientSettingsPolicies #2013

Merged
merged 7 commits into from
May 29, 2024

Conversation

kate-osborn
Copy link
Contributor

@kate-osborn kate-osborn commented May 22, 2024

Proposed changes

Problem: No automated functional tests for ClientSettingsPolicies.

Solution: Add functional tests for ClientSettingsPolicies.

Test Cases:

  • NGF writes the correct status on policies
    • Valid policies are accepted
    • Conflicting policies are marked as conflicted
    • Invalid policies are not accepted
  • NGF propagates the body.maxSize setting in the NGINX config. This is the only field in ClientSettingsPolicy that we can test e2e by sending traffic.

Closes #1762

Checklist

Before creating a PR, run through this checklist and mark each as complete.

  • I have read the CONTRIBUTING doc
  • I have added tests that prove my fix is effective or that my feature works
  • I have checked that all unit tests pass after adding my changes
  • I have updated necessary documentation
  • I have rebased my branch onto main
  • I will ensure my PR is targeting the main branch and pulling from my branch from my own fork

Release notes

If this PR introduces a change that affects users and needs to be mentioned in the release notes,
please add a brief note that summarizes the change.


@github-actions github-actions bot added the tests Pull requests that update tests label May 22, 2024
@kate-osborn kate-osborn marked this pull request as ready for review May 22, 2024 21:25
@kate-osborn kate-osborn requested a review from a team as a code owner May 22, 2024 21:25
@kate-osborn kate-osborn changed the title DRAFT- testing Add functional tests for ClientSettingsPolicies May 22, 2024
tests/suite/client_settings_test.go Outdated Show resolved Hide resolved
tests/suite/client_settings_test.go Outdated Show resolved Hide resolved
tests/suite/client_settings_test.go Outdated Show resolved Hide resolved
tests/suite/client_settings_test.go Outdated Show resolved Hide resolved
tests/suite/client_settings_test.go Show resolved Hide resolved
tests/suite/client_settings_test.go Show resolved Hide resolved
@github-actions github-actions bot added the documentation Improvements or additions to documentation label May 28, 2024
tests/go.mod Outdated Show resolved Hide resolved
@kate-osborn kate-osborn force-pushed the tests/client-settings branch 2 times, most recently from bf09b75 to 23a8513 Compare May 28, 2024 19:14
@kate-osborn kate-osborn requested a review from lucacome May 28, 2024 19:17
@kate-osborn kate-osborn merged commit 7281d3c into nginxinc:main May 29, 2024
40 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation tests Pull requests that update tests
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

Add automated functional tests for ClientSettingsPolicy
5 participants