Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » Unit Testing
Unit Testing [message #326472] Thu, 20 March 2008 13:17 Go to next message
Eclipse UserFriend
Originally posted by: alexjaquet.gmail.com

Hi,

I'm currently writting test unit and I need to pass an IFile to a
method, how can I retrieve that IFile

Thanks

Alexandre
Re: Unit Testing [message #326475 is a reply to message #326472] Thu, 20 March 2008 13:40 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: alexjaquet.gmail.com

I cannot do the following code

public void testSaveImages() throws Exception {
IWorkspace workspace = ResourcesPlugin.getWorkspace();
final IProject project = workspace.getRoot().getProject("test");
IFile file = project.getFile("module/condition.module");
IPath path = new Path("/");
int imageFormat = SWT.IMAGE_GIF;
SaveConditionUtils.createImages(file, path, imageFormat);

}

because the file as to be saved outside the workspace ...

Any idea welcome
Re: Unit Testing [message #326498 is a reply to message #326472] Fri, 21 March 2008 02:15 Go to previous message
Xiang Qinxian is currently offline Xiang QinxianFriend
Messages: 119
Registered: July 2009
Senior Member
Hi,

Do you find the run as plugintest item from launch menu?

Regards,

Qinxian

Alexandre Jaquet 写道:
> Hi,
>
> I'm currently writting test unit and I need to pass an IFile to a
> method, how can I retrieve that IFile
>
> Thanks
>
> Alexandre
Previous Topic:Changing a toolbar icon from within an IViewActionDelegate
Next Topic:Handler, activeWhen, PropertyTester and multiple selections
Goto Forum:
  


Current Time: Tue Jul 16 12:20:17 GMT 2024

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

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

Back to the top