Repository: flex-falcon
Updated Branches:
  refs/heads/develop 4b9b34815 -> 20b3a66ad


- Continued making the Unit-Tests use the TestAdapters


Project: http://git-wip-us.apache.org/repos/asf/flex-falcon/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-falcon/commit/20b3a66a
Tree: http://git-wip-us.apache.org/repos/asf/flex-falcon/tree/20b3a66a
Diff: http://git-wip-us.apache.org/repos/asf/flex-falcon/diff/20b3a66a

Branch: refs/heads/develop
Commit: 20b3a66add916cb8b7960d31a92bdd3ace18d948
Parents: 4b9b348
Author: Christofer Dutz <christofer.d...@codecentric.de>
Authored: Sun Mar 27 17:14:07 2016 +0200
Committer: Christofer Dutz <christofer.d...@codecentric.de>
Committed: Sun Mar 27 17:14:07 2016 +0200

----------------------------------------------------------------------
 .../apache/flex/compiler/internal/mxml/MXMLDataTests.java   | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-falcon/blob/20b3a66a/compiler.tests/unit-tests/org/apache/flex/compiler/internal/mxml/MXMLDataTests.java
----------------------------------------------------------------------
diff --git 
a/compiler.tests/unit-tests/org/apache/flex/compiler/internal/mxml/MXMLDataTests.java
 
b/compiler.tests/unit-tests/org/apache/flex/compiler/internal/mxml/MXMLDataTests.java
index da89b5a..be69f1d 100644
--- 
a/compiler.tests/unit-tests/org/apache/flex/compiler/internal/mxml/MXMLDataTests.java
+++ 
b/compiler.tests/unit-tests/org/apache/flex/compiler/internal/mxml/MXMLDataTests.java
@@ -35,11 +35,15 @@ import 
org.apache.flex.compiler.internal.workspaces.Workspace;
 import org.apache.flex.compiler.mxml.IMXMLData;
 import org.apache.flex.compiler.mxml.IMXMLDataManager;
 import org.apache.flex.utils.FilenameNormalization;
+import org.apache.flex.utils.ITestAdapter;
 import org.apache.flex.utils.StringUtils;
+import org.apache.flex.utils.TestAdapterFactory;
 import org.junit.Test;
 
 public class MXMLDataTests
 {
+       private ITestAdapter testAdapter = TestAdapterFactory.getTestAdapter();
+
        protected String getMXML(String[] code)
     {
         return StringUtils.join(code, "\n");
@@ -47,12 +51,11 @@ public class MXMLDataTests
        
        protected IMXMLData getMXMLData(String mxml)
        {
-               String tempDir = FilenameNormalization.normalize("temp"); // 
ensure this exists
-               
                File tempMXMLFile = null;
                try
                {
-                       tempMXMLFile = 
File.createTempFile(getClass().getSimpleName(), ".mxml", new File(tempDir));
+                       tempMXMLFile = 
File.createTempFile(getClass().getSimpleName(), ".mxml",
+                                       new File(testAdapter.getTempDir()));
                        tempMXMLFile.deleteOnExit();
 
                        BufferedWriter out = new BufferedWriter(new 
FileWriter(tempMXMLFile));

Reply via email to