Skip to content

Commit 2564e55

Browse files
committed
refactor: use inline insta snapshots for multiline table tests
Replace external .snap files with inline snapshot strings for the two multiline inline table insertion tests. https://claude.ai/code/session_01FT59TTz4yRy3DPwbREE82u
1 parent e53b25d commit 2564e55

3 files changed

Lines changed: 20 additions & 26 deletions

crates/pixi_manifest/src/toml/document.rs

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -445,7 +445,16 @@ dependencies = {
445445
)
446446
.unwrap();
447447

448-
insta::assert_snapshot!(manifest.0.to_string());
448+
insta::assert_snapshot!(manifest.0.to_string(), @r#"
449+
450+
[envs.python]
451+
channels = ["dummy-channel"]
452+
dependencies = {
453+
dummy = "3.11.*",
454+
other = "1.0",
455+
new-pkg = "2.0",
456+
}
457+
"#);
449458
}
450459

451460
/// Tests inserting into a multiline inline table where the last element
@@ -469,6 +478,15 @@ dependencies = {
469478
)
470479
.unwrap();
471480

472-
insta::assert_snapshot!(manifest.0.to_string());
481+
insta::assert_snapshot!(manifest.0.to_string(), @r#"
482+
483+
[envs.python]
484+
channels = ["dummy-channel"]
485+
dependencies = {
486+
dummy = "3.11.*",
487+
other = "1.0",
488+
new-pkg = "2.0"
489+
}
490+
"#);
473491
}
474492
}

crates/pixi_manifest/src/toml/snapshots/pixi_manifest__toml__document__tests__insert_into_multiline_inline_table.snap

Lines changed: 0 additions & 12 deletions
This file was deleted.

crates/pixi_manifest/src/toml/snapshots/pixi_manifest__toml__document__tests__insert_into_multiline_inline_table_no_trailing_comma.snap

Lines changed: 0 additions & 12 deletions
This file was deleted.

0 commit comments

Comments
 (0)