pub struct CaseGroup<T, G, P> { /* private fields */ }
Expand description
A easy to use test case collection struct that also provide functions for simple test case creation.
Implementations§
Source§impl<T, G, P> CaseGroup<T, G, P>
impl<T, G, P> CaseGroup<T, G, P>
Source§impl<G, P> CaseGroup<String, G, P>
Implement two handy methods on CaseGroup<String, G, P> struct.
impl<G, P> CaseGroup<String, G, P>
Implement two handy methods on CaseGroup<String, G, P> struct.
Sourcepub fn create(&mut self, ipt: &str, exp: Vec<G>)
pub fn create(&mut self, ipt: &str, exp: Vec<G>)
Create a new test case (no input parameters) matching &str and other generic types.
§Argument
ipt
- this argument is set to&str
to simplify method calls.exp
- expected values inVec<G>
form.
Sourcepub fn create_param(&mut self, ipt: &str, exp: Vec<G>, params: Vec<P>)
pub fn create_param(&mut self, ipt: &str, exp: Vec<G>, params: Vec<P>)
Create a new test case (with input parameters) matching &str and other generic types.
§Argument
ipt
- this argument is set to&str
to simplify method calls.exp
- expected values inVec<G>
form.params
- expected values inVec<P>
form.
Sourcepub fn create_multi(&mut self, ipts: Vec<&str>, exp: Vec<G>)
pub fn create_multi(&mut self, ipts: Vec<&str>, exp: Vec<G>)
Create a new test case (no input parameters but multiple inputs) matching &str and other generic types.
§Argument
ipts
- this argument is set to&str
to simplify method calls.exp
- expected values inVec<G>
form.
Sourcepub fn create_param_multi(
&mut self,
ipts: Vec<&str>,
exp: Vec<G>,
params: Vec<P>,
)
pub fn create_param_multi( &mut self, ipts: Vec<&str>, exp: Vec<G>, params: Vec<P>, )
Create a new test case (with input parameters and multiple inputs) matching &str and other generic types.
§Argument
ipts
- this argument is set to&str
to simplify method calls.exp
- expected values inVec<G>
form.params
- expected values inVec<P>
form.
Source§impl CaseGroup<i32, i32, i32>
Implement two handy methods on CaseGroup struct.
impl CaseGroup<i32, i32, i32>
Implement two handy methods on CaseGroup struct.
Sourcepub fn create(&mut self, ipt: i32, exp: Vec<i32>)
pub fn create(&mut self, ipt: i32, exp: Vec<i32>)
Create a new test case (no input parameters) matching selected generic types.
Sourcepub fn create_param(&mut self, ipt: i32, exp: Vec<i32>, params: Vec<i32>)
pub fn create_param(&mut self, ipt: i32, exp: Vec<i32>, params: Vec<i32>)
Create a new test case (with input parameters) matching selected generic types.
Source§impl CaseGroup<i32, String, i32>
Implement two handy methods on CaseGroup struct.
impl CaseGroup<i32, String, i32>
Implement two handy methods on CaseGroup struct.
Sourcepub fn create(&mut self, ipt: i32, exp: Vec<String>)
pub fn create(&mut self, ipt: i32, exp: Vec<String>)
Create a new test case (no input parameters) matching selected generic types.
Sourcepub fn create_param(&mut self, ipt: i32, exp: Vec<String>, params: Vec<i32>)
pub fn create_param(&mut self, ipt: i32, exp: Vec<String>, params: Vec<i32>)
Create a new test case (with input parameters) matching selected generic types.
Source§impl CaseGroup<i32, bool, i32>
Implement two handy methods on CaseGroup struct.
impl CaseGroup<i32, bool, i32>
Implement two handy methods on CaseGroup struct.
Sourcepub fn create(&mut self, ipt: i32, exp: Vec<bool>)
pub fn create(&mut self, ipt: i32, exp: Vec<bool>)
Create a new test case (no input parameters) matching selected generic types.
Sourcepub fn create_param(&mut self, ipt: i32, exp: Vec<bool>, params: Vec<i32>)
pub fn create_param(&mut self, ipt: i32, exp: Vec<bool>, params: Vec<i32>)
Create a new test case (with input parameters) matching selected generic types.
Source§impl CaseGroup<Vec<i32>, i32, i32>
Implement two handy methods on CaseGroup struct.
impl CaseGroup<Vec<i32>, i32, i32>
Implement two handy methods on CaseGroup struct.
Sourcepub fn create(&mut self, ipt: Vec<i32>, exp: Vec<i32>)
pub fn create(&mut self, ipt: Vec<i32>, exp: Vec<i32>)
Create a new test case (no input parameters) matching selected generic types.
Sourcepub fn create_param(&mut self, ipt: Vec<i32>, exp: Vec<i32>, params: Vec<i32>)
pub fn create_param(&mut self, ipt: Vec<i32>, exp: Vec<i32>, params: Vec<i32>)
Create a new test case (with input parameters) matching selected generic types.
Source§impl CaseGroup<Vec<i32>, Vec<Vec<i32>>, i32>
Implement two handy methods on CaseGroup struct.
impl CaseGroup<Vec<i32>, Vec<Vec<i32>>, i32>
Implement two handy methods on CaseGroup struct.
Sourcepub fn create(&mut self, ipt: Vec<i32>, exp: Vec<Vec<Vec<i32>>>)
pub fn create(&mut self, ipt: Vec<i32>, exp: Vec<Vec<Vec<i32>>>)
Create a new test case (no input parameters) matching selected generic types.
Sourcepub fn create_param(
&mut self,
ipt: Vec<i32>,
exp: Vec<Vec<Vec<i32>>>,
params: Vec<i32>,
)
pub fn create_param( &mut self, ipt: Vec<i32>, exp: Vec<Vec<Vec<i32>>>, params: Vec<i32>, )
Create a new test case (with input parameters) matching selected generic types.