Skip to main content



      Home
Home » Archived » Test and Performance Tools Platform (TPTP) » How to add attachments (files) to a test execution log
How to add attachments (files) to a test execution log [message #81310] Mon, 21 August 2006 12:41 Go to next message
Eclipse UserFriend
Hi,
All is in the title ... I just wonder how to send file from the RAC host
(where the test is executed) to the TPTP workbench (where the test log is
built). For example, i'd like to attach log files to execution events. How
can i achieve this ?

Thanks
Re: How to add attachments (files) to a test execution log [message #81354 is a reply to message #81310] Tue, 22 August 2006 04:03 Go to previous messageGo to next message
Eclipse UserFriend
Just a precision about this, I'm speaking about remote JUnit tests.
Re: How to add attachments (files) to a test execution log [message #98117 is a reply to message #81354] Mon, 07 May 2007 08:10 Go to previous message
Eclipse UserFriend
Hi Bertrand,
Yes, you can! Here is the code:

import org.eclipse.hyades.test.common.agent.PrimaryTestAgent;

import org.eclipse.hyades.test.common.event.EventAnnotation;

import org.eclipse.hyades.test.common.event.ExecutionEvent;

import org.eclipse.hyades.test.common.event.MessageEvent;



MessageEvent messageEvent = new MessageEvent();

messageEvent.setParentId(ExecutionEvent.ROOT_PARENT);

messageEvent.setSeverity(MessageEvent.INFO);

messageEvent.setText("This is my log file.");


EventAnnotation eventAnnotation = new EventAnnotation();

eventAnnotation.setFile(new File("C:\\myLog.log"));

eventAnnotation.setType("file");


messageEvent.addAnnotation(eventAnnotation);


PrimaryTestAgent.getComptestAgent().write(messageEvent.toStr ing());


Paul
"Bertrand Quenin" <bquenin@axway.com> wrote in message
news:ae9d57c1ec95cbb4bb9e7339a17cfc63$1@www.eclipse.org...
> Just a precision about this, I'm speaking about remote JUnit tests.
>
Previous Topic:Eclipse Testing Framework
Next Topic:Out of heap space when launching tests from ant driver
Goto Forum:
  


Current Time: Tue May 06 04:03:28 EDT 2025

Powered by FUDForum. Page generated in 0.26518 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top