]> git.vpit.fr Git - perl/modules/VPIT-TestHelpers.git/blobdiff - t/43-threads-unsafe-forced.t
Add threads feature
[perl/modules/VPIT-TestHelpers.git] / t / 43-threads-unsafe-forced.t
diff --git a/t/43-threads-unsafe-forced.t b/t/43-threads-unsafe-forced.t
new file mode 100644 (file)
index 0000000..ae05c60
--- /dev/null
@@ -0,0 +1,15 @@
+#!perl -T
+
+use strict;
+use warnings;
+
+BEGIN { $ENV{PERL_FORCE_TEST_THREADS} = 1 }
+
+use VPIT::TestHelpers threads => [ 'Not::Thread::Safe', 0 ];
+
+use Test::More tests => 1;
+
+fail 'force should not overrule thread-unsafe';
+
+my $thread = spawn sub { };
+$thread->join;