mirror of
https://github.com/Myriad-Dreamin/tinymist.git
synced 2025-07-19 18:55:01 +00:00
dev: use fixtures/playground
if name is not provided (#804)
This commit is contained in:
parent
41868aa0f4
commit
cadc70ceec
1 changed files with 2 additions and 0 deletions
|
@ -29,6 +29,8 @@ use crate::{
|
|||
type CompileDriver<C> = CompileDriverImpl<C, tinymist_world::LspCompilerFeat>;
|
||||
|
||||
pub fn snapshot_testing(name: &str, f: &impl Fn(&mut LocalContext, PathBuf)) {
|
||||
let name = if name.is_empty() { "playground" } else { name };
|
||||
|
||||
let mut settings = insta::Settings::new();
|
||||
settings.set_prepend_module_to_snapshot(false);
|
||||
settings.set_snapshot_path(format!("fixtures/{name}/snaps"));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue