place temp file inside extra directory

This commit is contained in:
Alexey Kudravtsev
2014-06-18 18:04:55 +04:00
parent 29571ad685
commit 6a5377e1c8
@@ -1,5 +1,5 @@
/*
* Copyright 2000-2012 JetBrains s.r.o.
* Copyright 2000-2014 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -62,7 +62,10 @@ public class EclipseImportWizardTest extends ProjectWizardTestCase {
}
public void testImportingFromTwoProviders() throws Exception {
File file = createTempFile("Foo.java", "class Foo {}");
File dir = createTempDirectory();
File file = new File(dir, "Foo.java");
FileUtil.writeToFile(file, "class Foo {}");
System.out.println("file = " + file);
Module module = importProjectFrom(file.getParent(), null, new ImportFromSourcesProvider(),
new EclipseProjectImportProvider(new EclipseImportBuilder()));
VirtualFile[] sourceRoots = ModuleRootManager.getInstance(module).getSourceRoots();