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

✨ Structured args in Testing #1541

Commits on May 26, 2021

  1. Testing: structured arguments

    This should make it a bit easier to manage argument overrides than the
    set of templates we have now, especially while we wait for
    componentconfig to be everywhere.
    
    Arguments can be defaulted, and those defaults can be overriden or
    appended to, and then finally render to a slice of strings to be passed
    as arguments and such.
    
    This should make it easier to configure the API server without needing
    to splat out the existing default arguments, maybe splice some stuff
    out, etc.
    
    For example:
    
    ```go
    apiServer.Configure().
      Disable("insecure-port").
      Append("vmodule", "httplog.go=10").
      Set("v", "5")
    ```
    DirectXMan12 committed May 26, 2021
    Configuration menu
    Copy the full SHA
    3758fc6 View commit details
    Browse the repository at this point in the history
  2. Testing: use structured arguments

    This converts the internal testing package to use structured arguments,
    introducing a new helper to preserve compat when specifying legacy args.
    DirectXMan12 committed May 26, 2021
    Configuration menu
    Copy the full SHA
    ddfdfdf View commit details
    Browse the repository at this point in the history