fix: stabilize rpg creation entry and opening cg

This commit is contained in:
kdletters
2026-05-21 17:21:38 +08:00
parent 0eed942ce5
commit 41075e41a2
26 changed files with 866 additions and 47 deletions

View File

@@ -54,9 +54,9 @@ pub fn default_creation_entry_type_snapshots(
"rpg",
"文字冒险",
"经典 RPG 体验",
"内测",
"可创建",
"/creation-type-references/rpg.webp",
false,
true,
true,
10,
updated_at_micros,

View File

@@ -236,6 +236,23 @@ mod tests {
);
}
#[test]
fn default_creation_entry_types_open_rpg_entry() {
let configs = default_creation_entry_type_snapshots(1);
let rpg = configs
.iter()
.find(|item| item.id == "rpg")
.expect("rpg creation entry should be seeded");
assert_eq!(rpg.title, "文字冒险");
assert_eq!(rpg.subtitle, "经典 RPG 体验");
assert!(rpg.visible);
assert!(rpg.open);
assert_eq!(rpg.badge, "可创建");
assert_eq!(rpg.sort_order, 10);
assert_eq!(rpg.image_src, "/creation-type-references/rpg.webp");
}
#[test]
fn default_creation_entry_types_include_bark_battle() {
let configs = default_creation_entry_type_snapshots(1);