common/tools/raptor/RaptorCommon.pm
author MattD <mattd@symbian.org>
Fri, 18 Sep 2009 14:03:50 +0100
changeset 468 eb9ba249e164
parent 383 52675b624b66
child 764 d00048f1b036
permissions -rw-r--r--
Added test targets 'sf-test-smoketest' and 'sf-test-bc-check' for the test team. They populate the drive, run the tests and zip the output. Minor fix was needed in the post build for zipping: '${build.drive}/output/logs/releaseables' must exist

# Copyright (c) 2009 Symbian Foundation Ltd
# This component and the accompanying materials are made available
# under the terms of the License "Eclipse Public License v1.0"
# which accompanies this distribution, and is available
# at the URL "http://www.eclipse.org/legal/epl-v10.html".
#
# Initial Contributors:
# Symbian Foundation Ltd - initial contribution.
#
# Contributors:
#
# Description:
# Common constants for the raptor parser suite

package RaptorCommon;

our $SEVERITY_CRITICAL = 'critical';
our $SEVERITY_MAJOR = 'major';
our $SEVERITY_MINOR = 'minor';

sub init
{
	my $filename = "$::basedir/summary.csv";
	if (!-f$filename)
	{
		print "Writing summary file $filename\n";
		open(SUMMARY, ">$filename");
		close(SUMMARY);
	}
}

sub dump_fault
{
	my ($category, $subcategory, $severity, $component, $phase, $recipe, $file, $line) = @_;
	
	open(SUMMARY, ">>$::basedir/summary.csv");
	print SUMMARY "$category,$subcategory,$severity,$::raptor_config,$component,$phase,$recipe,$file,$line\n";
	close(SUMMARY);
}

1;