More code coverage
This commit is contained in:
parent
4f2bb22420
commit
5a84833922
|
|
@ -316,3 +316,15 @@ pub trait Scenario where for<'a> &'a <<<Self as Scenario>::InitialEquipementList
|
|||
)
|
||||
}
|
||||
}
|
||||
#[cfg(test)]
|
||||
mod test {
|
||||
use super::RecipeCollection;
|
||||
use crate::weaponry_structs::{InitialEquipementList, equipement_structs::EqShape};
|
||||
|
||||
#[test]
|
||||
fn test_from_iter_intermediate() {
|
||||
let _b = <InitialEquipementList as RecipeCollection>::from_iter_intermediate::<EqShape>(
|
||||
[Ok(EqShape::default()), Ok(EqShape::default())].into_iter(),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -45,7 +45,8 @@ pub struct RefinedEquipement {
|
|||
/// The complete equipement list, refined with all advanced stats
|
||||
pub struct RefinedEquipementList {
|
||||
/// Inner list of Refined Equipements
|
||||
inner: Vec<RefinedEquipement>,
|
||||
// TODO[!]: The use of pub stays for the usage of the example showcasing the macro in export
|
||||
pub inner: Vec<RefinedEquipement>,
|
||||
}
|
||||
|
||||
// DONE: The use of Deref could be a subtle gotcha
|
||||
|
|
|
|||
|
|
@ -57,6 +57,7 @@ pub struct IndividualElementsScenario {
|
|||
|
||||
impl CrossRecipeScenario {
|
||||
/// Generate all the operations to be processed with the current config
|
||||
// TODO[!]: Consider adding to interface
|
||||
fn generate_selected_operation(
|
||||
&self,
|
||||
) -> Result<Vec<InitialEquipementList>, FatalEquipementError> {
|
||||
|
|
@ -134,3 +135,9 @@ impl Scenario for CrossRecipeScenario {
|
|||
&self.database
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
mod test {
|
||||
#[test]
|
||||
fn test_scenario() {}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -273,8 +273,7 @@ impl From<InnerEquipementStats> for EqFinishing {
|
|||
#[cfg(test)]
|
||||
mod test {
|
||||
use super::{
|
||||
EqFinishing, EqMaterial, EqNature, EqShape, Equipement, InitialEquipementList,
|
||||
InnerEquipementStats,
|
||||
EqFinishing, EqMaterial, EqShape, Equipement, InitialEquipementList, InnerEquipementStats,
|
||||
};
|
||||
use crate::interfaces::RecipeCollection;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue