summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorkdaniel2013-12-30 03:32:53 (EST)
committerkdaniel2013-12-30 03:33:17 (EST)
commit24b39e87bdec62bc7faa84a099cf770fc572eefe (patch)
tree250f2d73ce263d7898c16e1bc967a9dc331423f5
parentb8f8a913148e83b5f89e7fcea6d06442f6b9b7ba (diff)
downloadrt.equinox.p2-24b39e87bdec62bc7faa84a099cf770fc572eefe.zip
rt.equinox.p2-24b39e87bdec62bc7faa84a099cf770fc572eefe.tar.gz
rt.equinox.p2-24b39e87bdec62bc7faa84a099cf770fc572eefe.tar.bz2
bug 421935 & bug 422054 - an attempt to fix windows tests.refs/changes/88/20188/1
Added setting readonly using acl on win. Change-Id: I35dc0a2cad2490e3df4ba86d864bbf96d00ce824 Signed-off-by: kdaniel <krzysztof.daniel@gmail.com>
-rw-r--r--bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/reconciler/dropins/SharedInstallTestsProfileSpoofEnabledConfigured.java2
-rw-r--r--bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/simpleconfigurator/BundlesTxtTestExtendedConfigured.java2
-rw-r--r--bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/simpleconfigurator/SimpleConfiguratorTestExtendedConfigured.java2
-rw-r--r--bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/simpleconfigurator/SimpleConfiguratorUtilsExtendedConfiguredTest.java2
4 files changed, 8 insertions, 0 deletions
diff --git a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/reconciler/dropins/SharedInstallTestsProfileSpoofEnabledConfigured.java b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/reconciler/dropins/SharedInstallTestsProfileSpoofEnabledConfigured.java
index 07b085e..739eab6 100644
--- a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/reconciler/dropins/SharedInstallTestsProfileSpoofEnabledConfigured.java
+++ b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/reconciler/dropins/SharedInstallTestsProfileSpoofEnabledConfigured.java
@@ -73,10 +73,12 @@ public class SharedInstallTestsProfileSpoofEnabledConfigured extends SharedInsta
extensions = getTempFolder();
copy("", getTestData("", "testData/reconciler/extensions/ext1"), extensions);
setReadOnly(extensions, true);
+ AbstractSharedInstallTest.reallyReadOnly(extensions);
}
@Override
protected void tearDown() throws Exception {
+ AbstractSharedInstallTest.removeReallyReadOnly(extensions);
setReadOnly(extensions, false);
extensions.delete();
super.tearDown();
diff --git a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/simpleconfigurator/BundlesTxtTestExtendedConfigured.java b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/simpleconfigurator/BundlesTxtTestExtendedConfigured.java
index 0230a1b..2e08c54 100644
--- a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/simpleconfigurator/BundlesTxtTestExtendedConfigured.java
+++ b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/simpleconfigurator/BundlesTxtTestExtendedConfigured.java
@@ -29,6 +29,7 @@ public class BundlesTxtTestExtendedConfigured extends BundlesTxtTestExtended {
Activator.EXTENSIONS = testData.toString();
System.setProperty("p2.fragments", Activator.EXTENSIONS);
AbstractSharedInstallTest.setReadOnly(testData, true);
+ AbstractSharedInstallTest.reallyReadOnly(testData);
}
@Override
@@ -44,6 +45,7 @@ public class BundlesTxtTestExtendedConfigured extends BundlesTxtTestExtended {
@Override
protected void tearDown() throws Exception {
Activator.EXTENSIONS = null;
+ AbstractSharedInstallTest.removeReallyReadOnly(testData);
AbstractSharedInstallTest.setReadOnly(testData, false);
testData.delete();
super.tearDown();
diff --git a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/simpleconfigurator/SimpleConfiguratorTestExtendedConfigured.java b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/simpleconfigurator/SimpleConfiguratorTestExtendedConfigured.java
index c731738..115184d 100644
--- a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/simpleconfigurator/SimpleConfiguratorTestExtendedConfigured.java
+++ b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/simpleconfigurator/SimpleConfiguratorTestExtendedConfigured.java
@@ -39,12 +39,14 @@ public class SimpleConfiguratorTestExtendedConfigured extends SimpleConfigurator
ext3Info.createNewFile();
ext1Info.setLastModified(System.currentTimeMillis() + 1000);
AbstractSharedInstallTest.setReadOnly(ext1Parent, true);
+ AbstractSharedInstallTest.reallyReadOnly(ext1Parent);
ext3Info.setLastModified(System.currentTimeMillis() + 1000);
}
@Override
protected void tearDown() throws Exception {
Activator.EXTENSIONS = null;
+ AbstractSharedInstallTest.removeReallyReadOnly(ext1Parent);
AbstractSharedInstallTest.setReadOnly(ext1Parent, false);
super.tearDown();
}
diff --git a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/simpleconfigurator/SimpleConfiguratorUtilsExtendedConfiguredTest.java b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/simpleconfigurator/SimpleConfiguratorUtilsExtendedConfiguredTest.java
index b1a0029..efba873 100644
--- a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/simpleconfigurator/SimpleConfiguratorUtilsExtendedConfiguredTest.java
+++ b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/simpleconfigurator/SimpleConfiguratorUtilsExtendedConfiguredTest.java
@@ -33,6 +33,7 @@ public class SimpleConfiguratorUtilsExtendedConfiguredTest extends SimpleConfigu
copy("preparing readonly data", getTestData("simpleconfigurator extensions", "testData/simpleConfiguratorExtendedTest"), testData);
testData = new File(testData, "extensions");
AbstractSharedInstallTest.setReadOnly(testData.getParentFile(), true);
+ AbstractSharedInstallTest.reallyReadOnly(testData.getParentFile());
Activator.EXTENSIONS = testData.toString();
mainBundlesInfo = getTestData("simpleconfigurator extensions - main bundles.info", "testData/simpleConfiguratorExtendedTest/main/bundles.info");
@@ -41,6 +42,7 @@ public class SimpleConfiguratorUtilsExtendedConfiguredTest extends SimpleConfigu
@Override
protected void tearDown() throws Exception {
Activator.EXTENSIONS = null;
+ AbstractSharedInstallTest.removeReallyReadOnly(testData.getParentFile());
AbstractSharedInstallTest.setReadOnly(testData.getParentFile(), false);
testData.getParentFile().delete();
super.tearDown();