pub struct LambdaTestHarness { /* private fields */ }Expand description
Local Lambda testing harness for development and CI/CD
Implementations§
Source§impl LambdaTestHarness
impl LambdaTestHarness
pub fn new() -> LambdaTestHarness
pub fn with_context(self, context: TestContext) -> LambdaTestHarness
pub fn with_benchmarks( self, benchmarks: PerformanceBenchmarks, ) -> LambdaTestHarness
Sourcepub fn add_test_event(
&mut self,
event_type: LambdaEventType,
test_event: TestEvent,
)
pub fn add_test_event( &mut self, event_type: LambdaEventType, test_event: TestEvent, )
Add a custom test event
Sourcepub fn generate_test_suite(
&self,
annotations: &LambdaAnnotations,
) -> Result<String, Error>
pub fn generate_test_suite( &self, annotations: &LambdaAnnotations, ) -> Result<String, Error>
Generate test suite for a Lambda function
Sourcepub fn generate_cargo_lambda_test_script(
&self,
annotations: &LambdaAnnotations,
) -> Result<String, Error>
pub fn generate_cargo_lambda_test_script( &self, annotations: &LambdaAnnotations, ) -> Result<String, Error>
Generate a complete test script for cargo lambda test
Sourcepub fn generate_github_actions_workflow(
&self,
annotations: &LambdaAnnotations,
) -> Result<String, Error>
pub fn generate_github_actions_workflow( &self, annotations: &LambdaAnnotations, ) -> Result<String, Error>
Generate a GitHub Actions workflow for Lambda testing
Sourcepub fn generate_local_dev_script(&self) -> String
pub fn generate_local_dev_script(&self) -> String
Generate local development testing script
Sourcepub fn generate_load_test_script(
&self,
annotations: &LambdaAnnotations,
) -> Result<String, Error>
pub fn generate_load_test_script( &self, annotations: &LambdaAnnotations, ) -> Result<String, Error>
Generate load testing script
Trait Implementations§
Source§impl Clone for LambdaTestHarness
impl Clone for LambdaTestHarness
Source§fn clone(&self) -> LambdaTestHarness
fn clone(&self) -> LambdaTestHarness
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for LambdaTestHarness
impl Debug for LambdaTestHarness
Source§impl Default for LambdaTestHarness
impl Default for LambdaTestHarness
Source§fn default() -> LambdaTestHarness
fn default() -> LambdaTestHarness
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for LambdaTestHarness
impl RefUnwindSafe for LambdaTestHarness
impl Send for LambdaTestHarness
impl Sync for LambdaTestHarness
impl Unpin for LambdaTestHarness
impl UnwindSafe for LambdaTestHarness
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more