Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 1 addition & 5 deletions lambda-http/src/ext/extensions.rs
Original file line number Diff line number Diff line change
Expand Up @@ -108,10 +108,9 @@ pub trait RequestExt {
/// These will always be `None` for ALB triggered requests.
fn stage_variables_ref(&self) -> Option<&QueryMap>;

/// Configures instance with stage variables under `#[cfg(test)]` configurations
/// Configures instance with stage variables
///
/// This is intended for use in mock testing contexts.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this part of the comment still accurate?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I removed the added comments "under ... " because I removed the config annotation - the comment is now in the same form as the other with_ methods.

#[cfg(test)]
fn with_stage_variables<V>(self, variables: V) -> Self
where
V: Into<QueryMap>;
Expand Down Expand Up @@ -216,7 +215,6 @@ impl RequestExt for http::Extensions {
.and_then(|StageVariables(vars)| if vars.is_empty() { None } else { Some(vars) })
}

#[cfg(test)]
fn with_stage_variables<V>(self, variables: V) -> Self
where
V: Into<QueryMap>,
Expand Down Expand Up @@ -318,7 +316,6 @@ impl RequestExt for Parts {
self.extensions.stage_variables_ref()
}

#[cfg(test)]
fn with_stage_variables<V>(self, variables: V) -> Self
where
V: Into<QueryMap>,
Expand Down Expand Up @@ -420,7 +417,6 @@ impl<B> RequestExt for http::Request<B> {
self.extensions().stage_variables_ref()
}

#[cfg(test)]
fn with_stage_variables<V>(self, variables: V) -> Self
where
V: Into<QueryMap>,
Expand Down