mirror of
https://github.com/storytold/photocraft.git
synced 2026-12-02 06:20:48 +01:00
Discard the cancel reply in the continuation regression
This commit is contained in:
1 parent
f9bc661def
commit
2a942f2e07
4 files changed
+6
-1
No files matched your search
@@ -194,6 +194,7 @@ fn malformed_unknown_and_unrepresentable_descriptors_stay_whole() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// Unsupported options cannot become an approximate Photoshop event: keep native JSON or explicitly omit the step.
|
||||||
#[test]
|
#[test]
|
||||||
fn unsupported_native_targets_and_damaged_origins_use_exact_native_fallback() {
|
fn unsupported_native_targets_and_damaged_origins_use_exact_native_fallback() {
|
||||||
let loaded = imported(fixture("Lnr ", "Gcls", false));
|
let loaded = imported(fixture("Lnr ", "Gcls", false));
|
||||||
|
|||||||
@@ -211,6 +211,7 @@ fn caf_unrepresented_descriptors_are_kept_and_never_partially_play() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// Known native defaults become explicit values; unsupported defaults/options cannot disappear.
|
/// Known native defaults become explicit values; unsupported defaults/options cannot disappear.
|
||||||
|
/// Representable defaults use CAF events; every unrepresented option stays exact in native fallback and is omitted only on request.
|
||||||
#[test]
|
#[test]
|
||||||
fn caf_native_exports_preserve_effective_defaults_and_refuse_unrepresented_options() {
|
fn caf_native_exports_preserve_effective_defaults_and_refuse_unrepresented_options() {
|
||||||
for p in [json!({"sampling":"rectangular","output":"new"}), json!({"sampling":"rectangular","output":"new","seed":1,"target":"pixels"}), params()] {
|
for p in [json!({"sampling":"rectangular","output":"new"}), json!({"sampling":"rectangular","output":"new","seed":1,"target":"pixels"}), params()] {
|
||||||
|
|||||||
@@ -10,6 +10,7 @@ use photocraft_psd::{
|
|||||||
descriptor::Value as D,
|
descriptor::Value as D,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/// Load default export through the durable store, retaining every native ID and JSON parameter exactly.
|
||||||
pub fn preserved(set: &str, action: &Action) -> Vec<AtnItem> {
|
pub fn preserved(set: &str, action: &Action) -> Vec<AtnItem> {
|
||||||
let (bytes, skipped) = atn_cmds::export(set, &[action], &[], false).unwrap();
|
let (bytes, skipped) = atn_cmds::export(set, &[action], &[], false).unwrap();
|
||||||
assert!(skipped.is_empty());
|
assert!(skipped.is_empty());
|
||||||
|
|||||||
@@ -390,7 +390,9 @@ fn a_recorder_started_during_a_library_dialog_survives_its_continuation() {
|
|||||||
let second = dialog(&app);
|
let second = dialog(&app);
|
||||||
assert_ne!(first, second);
|
assert_ne!(first, second);
|
||||||
match exit {
|
match exit {
|
||||||
"cancel second" => crate::dialogs::cancel(&mut app, second).unwrap(),
|
"cancel second" => {
|
||||||
|
crate::dialogs::cancel(&mut app, second).unwrap();
|
||||||
|
}
|
||||||
"command error" => {
|
"command error" => {
|
||||||
app.ui.dialog_mut(second).unwrap().fields.insert("radius".into(), json!("invalid"));
|
app.ui.dialog_mut(second).unwrap().fields.insert("radius".into(), json!("invalid"));
|
||||||
assert!(crate::dialogs::confirm(&mut app, second).is_err());
|
assert!(crate::dialogs::confirm(&mut app, second).is_err());
|
||||||
|
|||||||
Reference in new issue
Block a user