import all tests from Fun
[p5sagit/Function-Parameters.git] / t / foreign / Fun / state.t
diff --git a/t/foreign/Fun/state.t b/t/foreign/Fun/state.t
new file mode 100644 (file)
index 0000000..6a05d24
--- /dev/null
@@ -0,0 +1,17 @@
+#!perl
+
+use strict;
+use warnings FATAL => 'all';
+use Test::More;
+
+use 5.10.0;
+use Function::Parameters;
+
+fun bar ($y) {
+    state $x = 10;
+    $x * $y;
+}
+
+is(bar(3), 30);
+
+done_testing;