Skip to content

Commit

Permalink
Fixup existing tests
Browse files Browse the repository at this point in the history
Signed-off-by: Benjamin Leggett <[email protected]>
  • Loading branch information
bleggett committed Sep 3, 2024
1 parent 952df6e commit 516857b
Showing 1 changed file with 13 additions and 13 deletions.
26 changes: 13 additions & 13 deletions spire-api/tests/delegated_identity_api_client_test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ mod integration_tests_delegate_identity_api_client {
use once_cell::sync::Lazy;
use spiffe::bundle::BundleRefSource;
use spiffe::{JwtBundleSet, TrustDomain};
use spire_api::{selectors, DelegatedIdentityClient};
use spire_api::{selectors, DelegateAttestationRequest, DelegatedIdentityClient};
use std::process::Command;
use tokio_stream::StreamExt;

Expand Down Expand Up @@ -38,9 +38,9 @@ mod integration_tests_delegate_identity_api_client {
let svid = client
.fetch_jwt_svids(
&["my_audience"],
vec![selectors::Selector::Unix(selectors::Unix::Uid(
get_uid() + 1,
))],
DelegateAttestationRequest::Selectors(vec![selectors::Selector::Unix(
selectors::Unix::Uid(get_uid() + 1),
)]),
)
.await
.expect("Failed to fetch JWT SVID");
Expand All @@ -52,9 +52,9 @@ mod integration_tests_delegate_identity_api_client {
async fn fetch_delegate_x509_svid() {
let mut client = get_client().await;
let response: spiffe::svid::x509::X509Svid = client
.fetch_x509_svid(vec![selectors::Selector::Unix(selectors::Unix::Uid(
get_uid() + 1,
))])
.fetch_x509_svid(DelegateAttestationRequest::Selectors(vec![
selectors::Selector::Unix(selectors::Unix::Uid(get_uid() + 1)),
]))
.await
.expect("Failed to fetch delegate SVID");
// Not checking the chain as the root is generated by spire.
Expand All @@ -71,9 +71,9 @@ mod integration_tests_delegate_identity_api_client {
let test_duration = std::time::Duration::from_secs(60);
let mut client = get_client().await;
let mut stream = client
.stream_x509_svids(vec![selectors::Selector::Unix(selectors::Unix::Uid(
get_uid() + 1,
))])
.stream_x509_svids(DelegateAttestationRequest::Selectors(vec![
selectors::Selector::Unix(selectors::Unix::Uid(get_uid() + 1)),
]))
.await
.expect("Failed to fetch delegate SVID");

Expand Down Expand Up @@ -124,9 +124,9 @@ mod integration_tests_delegate_identity_api_client {
let svids = client
.fetch_jwt_svids(
&["my_audience"],
vec![selectors::Selector::Unix(selectors::Unix::Uid(
get_uid() + 1,
))],
DelegateAttestationRequest::Selectors(vec![selectors::Selector::Unix(
selectors::Unix::Uid(get_uid() + 1),
)]),
)
.await
.expect("Failed to fetch JWT SVID");
Expand Down

0 comments on commit 516857b

Please sign in to comment.