-
Notifications
You must be signed in to change notification settings - Fork 95
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
attestation-agent: Extend ResourceUri to support query string #634
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.
LGTM. Thanks @cclaudio for this!
const TEST_QS_URL: &str = "kbs:///plugin/plugname/resourcename?param1=value1¶m2=value2"; | ||
|
||
#[test] | ||
fn deserialize_qs() { |
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.
rstest could help to make the tests more dry. I am sure that you will love it : )
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.
thanks, rstest definitely makes the code cleaner. Let me rework that test case
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.
LGTM
I will update this PR shortly with a edge case I forgot and also the test case clean-up |
With this change, the kbs-client is able to send a get-resource request that includes the query string provided e.g.: kbs-client --url http://127.0.0.1:8080 \ get-resource \ --path 'plugin/nebula/credential?ip[ip]=10.11.12.13&ip[netbits]=21&name=pod1' This is required by the KBS repository plugin interface. Signed-off-by: Claudio Carvalho <cclaudio@linux.ibm.com>
Done.
|
With this change, the kbs-client is able to send a get-resource request that includes the query string provided e.g.:
kbs-client --url http://127.0.0.1:8080
get-resource
--path 'plugin/nebula/credential?ip[ip]=10.11.12.13&ip[netbits]=21&name=pod1'
This is required by the KBS repository plugin interface.