Skip to content

Commit

Permalink
fix errors
Browse files Browse the repository at this point in the history
  • Loading branch information
mangas committed Dec 13, 2023
1 parent 382e29c commit 2b491f7
Showing 1 changed file with 23 additions and 23 deletions.
46 changes: 23 additions & 23 deletions runtime/test/src/test/abi.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,29 +5,29 @@ use graph::runtime::wasm::asc_abi::class::{

use super::*;

async fn test_unbounded_loop(api_version: Version) {
// Set handler timeout to 3 seconds.
let mut instance = test_valid_module_and_store_with_timeout(
"unboundedLoop",
mock_data_source(
&wasm_file_path("non_terminating.wasm", api_version.clone()),
api_version.clone(),
),
api_version,
Some(Duration::from_secs(3)),
)
.await
.0;
let res: Result<(), _> = instance
.get_func("loop")
.typed(&mut instance.store.as_context_mut())
.unwrap()
.call(&mut instance.store.as_context_mut(), ());
assert_eq!(
res.unwrap_err().to_string().lines().next().unwrap(),
"wasm trap: interrupt"
);
}
// async fn test_unbounded_loop(api_version: Version) {
// // Set handler timeout to 3 seconds.
// let mut instance = test_valid_module_and_store_with_timeout(
// "unboundedLoop",
// mock_data_source(
// &wasm_file_path("non_terminating.wasm", api_version.clone()),
// api_version.clone(),
// ),
// api_version,
// Some(Duration::from_secs(3)),
// )
// .await
// .0;
// let res: Result<(), _> = instance
// .get_func("loop")
// .typed(&mut instance.store.as_context_mut())
// .unwrap()
// .call(&mut instance.store.as_context_mut(), ());
// assert_eq!(
// res.unwrap_err().to_string().lines().next().unwrap(),
// "wasm trap: interrupt"
// );
// }

// #[tokio::test(flavor = "multi_thread")]
// async fn unbounded_loop_v0_0_4() {
Expand Down

0 comments on commit 2b491f7

Please sign in to comment.