summaryrefslogtreecommitdiff
path: root/tests/cffi.ur
diff options
context:
space:
mode:
Diffstat (limited to 'tests/cffi.ur')
-rw-r--r--tests/cffi.ur15
1 files changed, 15 insertions, 0 deletions
diff --git a/tests/cffi.ur b/tests/cffi.ur
index 039eac55..bcb9944c 100644
--- a/tests/cffi.ur
+++ b/tests/cffi.ur
@@ -8,7 +8,22 @@ fun effect () =
<button value="Either" onclick={Test.print}/>
</body></xml>
+fun xact () =
+ Test.transactional;
+ return <xml><body>
+ All good.
+ </body></xml>
+
+fun xact2 () =
+ Test.transactional;
+ error <xml>Failure</xml>;
+ return <xml><body>
+ All gooder.
+ </body></xml>
+
fun main () = return <xml><body>
{[Test.out (Test.frob (Test.create "Hello ") "world!")]}
<form><submit action={effect}/></form>
+ <form><submit action={xact}/></form>
+ <form><submit action={xact2}/></form>
</body></xml>