summaryrefslogtreecommitdiff
path: root/ACE/bin
diff options
context:
space:
mode:
authorJohnny Willemsen <jwillemsen@remedy.nl>2008-11-03 09:03:40 +0000
committerJohnny Willemsen <jwillemsen@remedy.nl>2008-11-03 09:03:40 +0000
commitbcb05c6b362d1739d548386ec4bca852ada39fa2 (patch)
treec8136e9c5cec8ce3991c1d5a43e698be16e15116 /ACE/bin
parentfc55cf2f0e503fe9b2dd6f33ee8216c23655c614 (diff)
downloadATCD-bcb05c6b362d1739d548386ec4bca852ada39fa2.tar.gz
Mon Nov 3 09:03:00 UTC 2008 Johnny Willemsen <jwillemsen@remedy.nl>
Diffstat (limited to 'ACE/bin')
-rw-r--r--ACE/bin/PerlACE/Run_Test.pm5
-rw-r--r--ACE/bin/PerlACE/TestTarget.pm19
-rw-r--r--ACE/bin/PerlACE/TestTarget_LVRT.pm9
-rw-r--r--ACE/bin/PerlACE/TestTarget_VxWorks.pm7
4 files changed, 33 insertions, 7 deletions
diff --git a/ACE/bin/PerlACE/Run_Test.pm b/ACE/bin/PerlACE/Run_Test.pm
index 2f063a4e233..29217351ac2 100644
--- a/ACE/bin/PerlACE/Run_Test.pm
+++ b/ACE/bin/PerlACE/Run_Test.pm
@@ -40,6 +40,11 @@ if ($PerlACE::LabVIEW_RT_Test) {
require PerlACE::ProcessLVRT;
}
+$PerlACE::WinCE_Test = $config->check_config("WINCE");
+if ($PerlACE::WinCE_Test) {
+ require PerlACE::ProcessWinCE;
+}
+
# Figure out the svc.conf extension
$svcconf_ext = $ENV{"ACE_RUNTEST_SVCCONF_EXT"};
if (!defined $svcconf_ext) {
diff --git a/ACE/bin/PerlACE/TestTarget.pm b/ACE/bin/PerlACE/TestTarget.pm
index 98f9b8292e2..20e0141b11f 100644
--- a/ACE/bin/PerlACE/TestTarget.pm
+++ b/ACE/bin/PerlACE/TestTarget.pm
@@ -53,6 +53,11 @@ sub create_target
$target = new PerlACE::TestTarget_VxWorks ($config_name);
last SWITCH;
}
+ if ($config_os =~ /WinCE/i) {
+ require PerlACE::TestTarget_WinCE;
+ $target = new PerlACE::TestTarget_WinCE ($config_name);
+ last SWITCH;
+ }
print STDERR "$config_os is an unknown OS type!\n";
}
return $target;
@@ -181,14 +186,18 @@ sub LocalFile ($)
my $self = shift;
my $file = shift;
my $newfile = PerlACE::LocalFile($file);
- print STDERR "LocalFile for $file is $newfile\n";
+ if (defined $ENV{'ACE_TEST_VERBOSE'}) {
+ print STDERR "LocalFile for $file is $newfile\n";
+ }
return $newfile;
}
sub DeleteFile ($)
{
my $self = shift;
- unlink (@_);
+ my $file = shift;
+ my $newfile = PerlACE::LocalFile($file);
+ unlink ($newfile);
}
sub GetFile ($)
@@ -205,10 +214,11 @@ sub PutFile ($)
{
my $self = shift;
my $src = shift;
- my $dest = shift;
+ my $dest = $self->LocalFile ($src);
if ($src != $dest) {
copy ($src, $dest);
}
+ return 0;
}
sub WaitForFileTimed ($)
@@ -216,7 +226,8 @@ sub WaitForFileTimed ($)
my $self = shift;
my $file = shift;
my $timeout = shift;
- return PerlACE::waitforfile_timed ($file, $timeout);
+ my $newfile = $self->LocalFile($file);
+ return PerlACE::waitforfile_timed ($newfile, $timeout);
}
sub CreateProcess ($)
diff --git a/ACE/bin/PerlACE/TestTarget_LVRT.pm b/ACE/bin/PerlACE/TestTarget_LVRT.pm
index f12378f920c..3e5df034e44 100644
--- a/ACE/bin/PerlACE/TestTarget_LVRT.pm
+++ b/ACE/bin/PerlACE/TestTarget_LVRT.pm
@@ -132,7 +132,8 @@ sub DeleteFile ($)
my $self = shift;
$self->{FTP}->login("","");
foreach my $file (@_) {
- $self->{FTP}->delete($file);
+ my $newfile = $self->LocalFile($file);
+ $self->{FTP}->delete($newfile);
}
}
@@ -142,8 +143,9 @@ sub GetFile ($)
my $self = shift;
my $remote_file = shift;
my $local_file = shift;
+ my $newfile = $self->LocalFile($file);
$self->{FTP}->ascii();
- if ($self->{FTP}->get($remote_file, $local_file)) {
+ if ($self->{FTP}->get($newfile, $local_file)) {
return 0;
}
return -1;
@@ -154,6 +156,7 @@ sub WaitForFileTimed ($)
my $self = shift;
my $file = shift;
my $timeout = shift;
+ my $newfile = $self->LocalFile($file);
my $targetport = $self->{CTLPORT};
my $target = new Net::Telnet(Errmode => 'return');
if (!$target->open(Host => $self->{IPNAME}, Port => $targetport)) {
@@ -161,7 +164,7 @@ sub WaitForFileTimed ($)
$target->errmsg(), "\n";
return -1;
}
- my $cmdline = "waitforfile $file $timeout";
+ my $cmdline = "waitforfile $newfile $timeout";
if (defined $ENV{'ACE_TEST_VERBOSE'}) {
print "-> $cmdline\n";
}
diff --git a/ACE/bin/PerlACE/TestTarget_VxWorks.pm b/ACE/bin/PerlACE/TestTarget_VxWorks.pm
index 18c26f6e1d8..c4db4cfa753 100644
--- a/ACE/bin/PerlACE/TestTarget_VxWorks.pm
+++ b/ACE/bin/PerlACE/TestTarget_VxWorks.pm
@@ -50,5 +50,12 @@ sub RebootNow ($)
reboot ();
}
+sub WaitForFileTimed ($)
+{
+ my $self = shift;
+ my $file = shift;
+ my $timeout = shift;
+ return 0;
+}
1;