equal
deleted
inserted
replaced
|
1 # |
|
2 # Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). |
|
3 # All rights reserved. |
|
4 # This component and the accompanying materials are made available |
|
5 # under the terms of "Eclipse Public License v1.0" |
|
6 # which accompanies this distribution, and is available |
|
7 # at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 # |
|
9 # Initial Contributors: |
|
10 # Nokia Corporation - initial contribution. |
|
11 # |
|
12 # Contributors: |
|
13 # |
|
14 # Description: |
|
15 # |
|
16 |
|
17 // html_file_copier.pl |
|
18 // |
|
19 // Copyright (c) 2007 - 2008 Symbian Software Ltd. All rights reserved. |
|
20 // |
|
21 |
|
22 use warnings; |
|
23 use strict; |
|
24 use File::Copy; |
|
25 |
|
26 my $resDir = `testdriver resultpath`; |
|
27 chomp $resDir; |
|
28 print "$resDir\n"; |
|
29 if($resDir=~/^(.*testdriver\\[^\\]+\\armv5\\udeb\\)\d+\\$/) |
|
30 { |
|
31 print "$1\n"; |
|
32 my $prevDir = $1; |
|
33 my @files = <$prevDir*>; |
|
34 foreach my $file (@files) |
|
35 { |
|
36 print "$file\n"; |
|
37 if(-d $file) |
|
38 { |
|
39 print "Setting resDir: $resDir\n"; |
|
40 $resDir = $file . "\\"; |
|
41 next; |
|
42 } |
|
43 } |
|
44 } |
|
45 |
|
46 if($resDir=~/^(.*testdriver\\)([^\\]+)\\armv5\\udeb\\(\d+)\\$/) |
|
47 { |
|
48 my $outputDir = $1; |
|
49 my $build = $2; |
|
50 my $run = $3; |
|
51 my $input = "$resDir" . "run$run\_$build.html"; |
|
52 print "Input: $input\n"; |
|
53 my $output = "$outputDir". "out.html"; |
|
54 print "Output: $output\n"; |
|
55 if(!copy($input, $output)) |
|
56 { |
|
57 print "Couldn't copy results"; |
|
58 exit (2); |
|
59 } |
|
60 } |
|
61 else |
|
62 { |
|
63 print "Couldn't find results"; |
|
64 exit(1); |
|
65 } |