Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test: set AuthToken in tests to match Client code (#24792)
tl;dr - runtime code is fine but tests should match reality The Nomad Client Agent is the only consumer of the `Node.Derive{SI,Vault}Token` RPCs, therefore tests of the RPCs should match Nomad Client behavior. - DeriveVaultToken code: https://github.com/hashicorp/nomad/blob/a9ee66a6ef358097783d1bf745051124cc0f14f2/client/client.go#L2904-L2917 - DeriveSIToken code: https://github.com/hashicorp/nomad/blob/a9ee66a6ef358097783d1bf745051124cc0f14f2/client/client.go#L2988-L2997 Both of those client code paths include the Node SecretID in both the request's SecretID field as well as the embedded `QueryOptions.AuthToken` field. This patch updates server tests to match that behavior. The tests pass either way.
- Loading branch information