diff --git a/crates/flowproof-cli/tests/examples_resolve.rs b/crates/flowproof-cli/tests/examples_resolve.rs index 6924677..95d4b70 100644 --- a/crates/flowproof-cli/tests/examples_resolve.rs +++ b/crates/flowproof-cli/tests/examples_resolve.rs @@ -6,6 +6,8 @@ use flowproof_agent::{FlowSpec, SuiteManifest}; const FIORI_SPEC: &str = include_str!("../../../examples/fiori/manage-info-records.flow.yaml"); +const PURCHASE_INFO_RECORDS_SPEC: &str = + include_str!("../../../examples/fiori/purchase-info-records-report.flow.yaml"); const FIORI_SUITE: &str = include_str!("../../../examples/fiori/suite.yaml"); const CONN_TEST_SPEC: &str = include_str!("../../../examples/api/connection-test.flow.yaml"); /// The npm-path agent quickstart. It is the first example a reader coming @@ -65,6 +67,21 @@ fn fiori_example_resolves_entirely_via_rules() { } } +/// Unlike `fiori_example_resolves_entirely_via_rules`, this example's header +/// deliberately promises two flagged TODOs left unresolved for `flowproof +/// record` to fill in against the live screen, not guessed here — so this +/// test only proves the file parses, and does not run every step through +/// `rules::resolve_step` (the two TODO steps are plain prose by design and +/// are not expected to resolve). +#[test] +fn purchase_info_records_example_parses_as_a_multi_surface_flow() { + let spec = FlowSpec::parse(PURCHASE_INFO_RECORDS_SPEC).expect("example parses"); + assert!( + spec.apps.contains_key("fiori") && spec.apps.contains_key("excel"), + "flow declares both the fiori and excel surfaces" + ); +} + #[test] fn fiori_suite_manifest_declares_the_data_leg() { let manifest: SuiteManifest = serde_yaml::from_str(FIORI_SUITE).expect("suite.yaml parses"); diff --git a/examples/fiori/purchase-info-records-report.flow.yaml b/examples/fiori/purchase-info-records-report.flow.yaml index 586ed77..7a42d0e 100644 --- a/examples/fiori/purchase-info-records-report.flow.yaml +++ b/examples/fiori/purchase-info-records-report.flow.yaml @@ -49,9 +49,7 @@ steps: # single clear target ("Manage Info Records" / "Display purchasing # info records by Supplier" / "Display purchasing info records by # material") — resolve against the live tile catalog at record time. - # This is a best-effort guess at the tile's visible text, not a - # confirmed label. - - Click "Display Purchasing Info Record" + - resolve the tile to click against the live catalog — no single clear target is named. Observed - the PDF's Step 3 lists three near-identical options — "Manage Info Records", "Display purchasing info records by Supplier", "Display purchasing info records by material". - assert: page shows Info Record # -- Search the standard info record by the minted test data -------