summaryrefslogtreecommitdiff
path: root/tests/async.rs
diff options
context:
space:
mode:
authorAlex Orlenko <zxteam@protonmail.com>2023-07-10 22:41:03 +0100
committerAlex Orlenko <zxteam@protonmail.com>2023-07-10 22:41:03 +0100
commit7dc6e4c1329931221bdb7d1504d97de46e068865 (patch)
treecdb9fb08d3dbc398f72eb63b6ce0e4375da0946e /tests/async.rs
parent44b8c8b7a6934744ada38dddd04e48f2d1df750a (diff)
downloadmlua-7dc6e4c1329931221bdb7d1504d97de46e068865.zip
Add `Error::runtime()` helper
Diffstat (limited to 'tests/async.rs')
-rw-r--r--tests/async.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/async.rs b/tests/async.rs
index e747033..f3094c5 100644
--- a/tests/async.rs
+++ b/tests/async.rs
@@ -340,7 +340,7 @@ async fn test_async_thread_pool() -> Result<()> {
let error_f = lua.create_async_function(|_, ()| async move {
sleep_ms(10).await;
- Err::<(), _>(Error::RuntimeError("test".to_string()))
+ Err::<(), _>(Error::runtime("test"))
})?;
let sleep = lua.create_async_function(|_, n| async move {