summaryrefslogtreecommitdiff
path: root/test/module/test.pl
diff options
context:
space:
mode:
Diffstat (limited to 'test/module/test.pl')
-rwxr-xr-xtest/module/test.pl30
1 files changed, 30 insertions, 0 deletions
diff --git a/test/module/test.pl b/test/module/test.pl
new file mode 100755
index 0000000..0853f79
--- /dev/null
+++ b/test/module/test.pl
@@ -0,0 +1,30 @@
+#!/usr/bin/perl
+
+use Getopt::Long;
+my $train;
+my $test;
+GetOptions (
+ "train" => \$train,
+ "test" => \$test
+)
+or die("Error in command line arguments\n");
+
+print "hello i am a perl script :o)\n";
+
+if ($train) {
+ print "we are training...\n";
+ for (my $i = 0; $i < 10; $i++) {
+ print "$i...\n";
+ sleep 1;
+ }
+} elsif ($test) {
+ print "we are testing...\n";
+ for (my $i = 0; $i < 10; $i++) {
+ print "$i...\n";
+ sleep 1;
+ }
+} else {
+ die "unknown command!";
+}
+
+exit;