Module: check_mk
Branch: master
Commit: 6177d1238b86c87307075810eaea36661969856e
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=6177d1238b86c8…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Wed May 30 08:24:05 2018 +0200
Test that some often used perl modules are available
Change-Id: I4160130704ff8d6749dd8ff8666427eea900821f
---
tests/integration/omd/test_perl.py | 47 ++++++++++++++++++++++++++++++++++++++
1 file changed, 47 insertions(+)
diff --git a/tests/integration/omd/test_perl.py b/tests/integration/omd/test_perl.py
new file mode 100644
index 0000000..4d5da07
--- /dev/null
+++ b/tests/integration/omd/test_perl.py
@@ -0,0 +1,47 @@
+
+def test_perl_modules(site):
+ # TODO: Complete this list
+ test_modules = [
+ "Getopt::Long",
+ "File::stat",
+ "File::Find",
+ "File::Path",
+ "Net::SNMP",
+ "SNMP",
+ "Nagios::Plugin",
+ "Test::Simple",
+ "Try::Tiny",
+ "Params::Validate",
+ "Module::Runtime",
+ "Module::Metadata",
+ "Module::Implementation",
+ "Module::Build",
+ "Math::Calc::Units",
+ "Config::Tiny",
+ "Class::Accessor",
+
+ # Webinject
+ "Carp",
+ "LWP",
+ "URI",
+ "HTTP::Request::Common",
+ "HTTP::Cookies",
+ "XML::Simple",
+ "Time::HiRes",
+ "Crypt::SSLeay",
+ "XML::Parser",
+ "Data::Dumper",
+ "File::Temp",
+
+ # Check_oracle_health
+ "File::Basename",
+ "IO::File",
+ "File::Copy",
+ "Sys::Hostname",
+ "Data::Dumper",
+ "Net::Ping",
+ ]
+
+ for module in test_modules:
+ p = site.execute(["perl", "-e", "use %s" %
module])
+ assert p.wait() == 0, "Failed to load module: %s" % module