Bad database selected

This commit is contained in:
Dandaedre 2025-02-22 02:06:22 +01:00
parent a231dfdd19
commit 04bc4d57ec
Signed by: Dandaedre
GPG Key ID: 440C6592E8A26D99
2 changed files with 8 additions and 5 deletions

View File

@ -16,10 +16,10 @@ serde_json = { version = "1.0.138", features = ["alloc"] }
strum = { version = "0.27.0", features = ["derive"] }
thiserror = "2.0.11"
regex = "1.11.1"
charming = { version = "0.4.0", features = ["deno_core", "image", "resvg", "ssr", "wasm"] }
chrono = "0.4.39"
leptos = { version = "0.7.7", features = ["csr"] }
leptos-use = "0.15"
charming = { version = "0.4.0", features = [] }
# chrono = "0.4.39"
# leptos = { version = "0.7.7", features = ["csr"] }
# leptos-use = "0.15"
[dev-dependencies]
criterion = { version = "0.5" }

View File

@ -47,6 +47,8 @@ impl ViewTable for ViewtableMock {
/// A simple cross recipe scenario
#[allow(clippy::missing_docs_in_private_items)]
pub struct CrossRecipeScenario {
// TODO: Should obv be inside the config
database_name: String,
database: EquipementDatabase,
config: ConfigMock,
}
@ -63,7 +65,7 @@ impl CrossRecipeScenario {
Ok(InitialEquipementList::from_vectored(
self.database
.serialize_vec_from_table::<DatabaseEquipementStats>(
&name,
&self.database_name,
Some(&format!("META_CATEGORY LIKE '{}'", name)),
)?
.into_iter()
@ -89,6 +91,7 @@ impl Scenario for CrossRecipeScenario {
{
Ok(Self {
// TODO: Correct this relative path abomination
database_name: "Equipements".into(),
database: Self::DatabaseType::new("./databases/weapons.db")?,
config,
})