Skip to content

Commit

Permalink
fix tests with new API
Browse files Browse the repository at this point in the history
  • Loading branch information
DougAnderson444 committed Jan 8, 2024
1 parent 4e2409f commit 9c56cc2
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 8 deletions.
8 changes: 4 additions & 4 deletions examples/crates/aggregate-wit-ui/tests/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -188,12 +188,12 @@ mod aggregate_example_tests {
// Now we should be able to pass this content as context to render()

let seed_ui = SeedContext::AllContent(bindgen::seed_keeper::wit_ui::wurbo_types::Content {
page: Page {
page: Some(Page {
title: "a title for the page".to_string(),
},
input: bindgen::seed_keeper::wit_ui::wurbo_types::Input {
}),
input: Some(bindgen::seed_keeper::wit_ui::wurbo_types::Input {
placeholder: "a placeholder".to_string(),
},
}),
output: None,
});

Expand Down
14 changes: 10 additions & 4 deletions examples/crates/aggregate-wit-ui/wit/deps/seed-keeper-ui/types.wit
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ interface wurbo-types {
value: string,
}

type encrypted = list<u8>;

record output {
// the resulting value of the total outputs combined
value: option<string>,
Expand All @@ -29,13 +31,15 @@ interface wurbo-types {
// the output dest for the username changes
username: option<outrecord>,
// the output dest for the password changes
password: option<outrecord>
password: option<outrecord>,
// the output dest for the encrypted changes
encrypted: option<encrypted>,
}

// COntent for the entire page
// Content for the entire page
record content {
page: page,
input: input,
page: option<page>,
input: option<input>,
output: option<output>
}

Expand All @@ -44,6 +48,8 @@ interface wurbo-types {
all-content(content),
username(outrecord),
password(outrecord),
encrypted(encrypted),
submit
}

}

0 comments on commit 9c56cc2

Please sign in to comment.