Fix RT bug #46086
[gitmo/MooseX-Singleton.git] / t / warnings_once.t
diff --git a/t/warnings_once.t b/t/warnings_once.t
new file mode 100644 (file)
index 0000000..696cbe5
--- /dev/null
@@ -0,0 +1,14 @@
+# test script for: https://rt.cpan.org/Ticket/Display.html?id=46086
+use Test::More qw(no_plan);
+use Test::NoWarnings;
+
+BEGIN {
+    package OnlyUsedOnce;
+    use strict;
+    use warnings;
+    use MooseX::Singleton;
+}
+
+BEGIN { OnlyUsedOnce->initialize; }
+
+my $s = OnlyUsedOnce->instance;