aboutsummaryrefslogtreecommitdiffstats
path: root/tests/xxx_mdx_plugin_recma_document.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/xxx_mdx_plugin_recma_document.rs')
-rw-r--r--tests/xxx_mdx_plugin_recma_document.rs7
1 files changed, 3 insertions, 4 deletions
diff --git a/tests/xxx_mdx_plugin_recma_document.rs b/tests/xxx_mdx_plugin_recma_document.rs
index 1cb91fe..9106c50 100644
--- a/tests/xxx_mdx_plugin_recma_document.rs
+++ b/tests/xxx_mdx_plugin_recma_document.rs
@@ -24,10 +24,9 @@ fn from_markdown(value: &str) -> Result<String, String> {
},
)?;
let hast = mdast_util_to_hast(&mdast);
- let program = hast_util_to_swc(&hast, None, Some(&location))?;
- let program = mdx_plugin_recma_document(program, &DocumentOptions::default(), Some(&location))?;
- let value = serialize(&program.module);
- Ok(value)
+ let mut program = hast_util_to_swc(&hast, None, Some(&location))?;
+ mdx_plugin_recma_document(&mut program, &DocumentOptions::default(), Some(&location))?;
+ Ok(serialize(&program.module))
}
#[test]