Skipping the test under Windows.

git-svn-id: svn+ssh://dev.eclipse.org/svnroot/rt/org.eclipse.jetty/jetty/trunk@2955 7e9141cc-0065-0410-87d8-b60c137991c4
This commit is contained in:
Simone Bordet 2011-04-01 15:28:13 +00:00
parent c7cd3c3233
commit d99f4e276b
1 changed files with 35 additions and 27 deletions

View File

@ -1,6 +1,5 @@
package org.eclipse.jetty.util; package org.eclipse.jetty.util;
import java.io.File; import java.io.File;
import java.io.FileOutputStream; import java.io.FileOutputStream;
import java.io.IOException; import java.io.IOException;
@ -10,9 +9,9 @@ import java.util.concurrent.LinkedBlockingQueue;
import java.util.concurrent.TimeUnit; import java.util.concurrent.TimeUnit;
import junit.framework.Assert; import junit.framework.Assert;
import org.eclipse.jetty.util.Scanner.Notification; import org.eclipse.jetty.util.Scanner.Notification;
import org.junit.AfterClass; import org.junit.AfterClass;
import org.junit.Assume;
import org.junit.BeforeClass; import org.junit.BeforeClass;
import org.junit.Test; import org.junit.Test;
@ -83,9 +82,16 @@ public class ScannerTest
} }
} }
private void assumeNotWindows()
{
Assume.assumeTrue(!System.getProperty("os.name").toLowerCase().contains("windows"));
}
@Test @Test
public void testAddedChangeRemove() throws Exception public void testAddedChangeRemove() throws Exception
{ {
assumeNotWindows();
touch("a0"); touch("a0");
// takes 2s to notice a0 and check that it is stable // takes 2s to notice a0 and check that it is stable
@ -177,6 +183,8 @@ public class ScannerTest
@Test @Test
public void testSizeChange() throws Exception public void testSizeChange() throws Exception
{ {
assumeNotWindows();
touch("tsc0"); touch("tsc0");
// takes 2s to notice tsc0 and check that it is stable. This syncs us with the scan // takes 2s to notice tsc0 and check that it is stable. This syncs us with the scan