Revision: 19622
          http://sourceforge.net/p/gate/code/19622
Author:   markagreenwood
Date:     2016-10-04 07:15:52 +0000 (Tue, 04 Oct 2016)
Log Message:
-----------
renabled a whole bunch more tests

Modified Paths:
--------------
    gate/branches/sawdust2/gate-core/src/test/java/gate/html/TestHtml.java

Added Paths:
-----------
    
gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestAnnotationMerging.java
    
gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestClassificationMeasures.java
    gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestDiffer.java
    gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestFeatureMap.java
    gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestRBTreeMap.java
    gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestTools.java
    
gate/branches/sawdust2/gate-core/src/test/resources/gate/resources/gate.ac.uk/tests/ft-bt-03-aug-2001.html

Removed Paths:
-------------
    
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestAnnotationMerging.java
    
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestClassificationMeasures.java
    gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestDiffer.java
    
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestFeatureMap.java
    
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestRBTreeMap.java
    gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestTools.java

Deleted: 
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestAnnotationMerging.java
===================================================================
--- 
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestAnnotationMerging.java
     2016-10-04 05:35:22 UTC (rev 19621)
+++ 
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestAnnotationMerging.java
     2016-10-04 07:15:52 UTC (rev 19622)
@@ -1,168 +0,0 @@
-package gate.util;
-
-import gate.Annotation;
-import gate.AnnotationSet;
-import gate.Corpus;
-import gate.Document;
-import gate.Factory;
-import gate.Gate;
-import gate.GateConstants;
-import gate.corpora.TestDocument;
-
-import java.net.URL;
-import java.util.HashMap;
-
-import junit.framework.Test;
-import junit.framework.TestCase;
-import junit.framework.TestSuite;
-
-public class TestAnnotationMerging extends TestCase {
-  /** The id of test case. */
-  int caseN;
-
-  /** Construction */
-  public TestAnnotationMerging(String name) {
-    super(name);
-  }
-
-  /** Fixture set up */
-  @Override
-  public void setUp() {
-  } // setUp
-
-  /**
-   * Put things back as they should be after running tests.
-   */
-  @Override
-  public void tearDown() throws Exception {
-  } // tearDown
-
-  /** Test suite routine for the test runner */
-  public static Test suite() {
-    return new TestSuite(TestAnnotationMerging.class);
-  } // suite
-
-  private Document loadDocument(String path, String name) throws Exception {
-    Document doc = Factory.newDocument(new 
URL(TestDocument.getTestServerName()+path), "UTF-8");
-    doc.setName(name);
-    return doc;
-  }
-
-  /** The test for AnnotationMerging. */
-  public void testAnnotationMerging() throws Exception {
-
-    Boolean savedSpaceSetting = Gate.getUserConfig().getBoolean(
-            GateConstants.DOCUMENT_ADD_SPACE_ON_UNPACK_FEATURE_NAME);
-    Gate.getUserConfig().put(
-            GateConstants.DOCUMENT_ADD_SPACE_ON_UNPACK_FEATURE_NAME,
-            Boolean.FALSE);
-    try {
-
-      //Gate.setGateHome(new File("C:\\svn\\gate"));
-      //Gate.setUserConfigFile(new File("C:\\svn\\gate.xml"));
-      //Gate.init();
-      // Load the documents into a corpus
-      Corpus data = Factory.newCorpus("data");
-      // Put the annotated document into a matrix for IAA
-      String nameAnnSet;
-      String nameAnnType = "";
-      String nameAnnFeat = "";
-      // Use the dataset of one document and three annotators
-      data.add(loadDocument("tests/iaa/beijing-opera.xml", 
"beijing-opera.xml"));
-      //ExtensionFileFilter fileFilter = new ExtensionFileFilter();
-      //fileFilter.addExtension("xml");
-      //data.populate(new 
File("C:\\yaoyong_h\\work\\iaa\\data\\smallData").toURI().toURL(), fileFilter, 
"UTF-8", false);
-      
-      nameAnnSet = "ann1;ann2;ann3";
-      boolean isUsingMajority=false;
-      nameAnnType = "sent";
-      nameAnnFeat = "Op";
-      caseN = 1;
-      isUsingMajority=true;
-      testWithfeat(nameAnnSet, nameAnnType, nameAnnFeat,
-              data, isUsingMajority);
-      
-      caseN = 2;
-      isUsingMajority=false;
-      testWithfeat(nameAnnSet, nameAnnType, nameAnnFeat,
-              data, isUsingMajority);
-
-      
-      nameAnnType = "Os";
-      nameAnnFeat = null;
-      caseN = 3;
-      isUsingMajority=true;
-      testWithfeat(nameAnnSet, nameAnnType, nameAnnFeat, data, 
isUsingMajority);
-      
-      caseN = 4;
-      isUsingMajority=false;
-      testWithfeat(nameAnnSet, nameAnnType, nameAnnFeat, data, 
isUsingMajority);
-    }
-    finally {
-      Gate.getUserConfig().put(
-              GateConstants.DOCUMENT_ADD_SPACE_ON_UNPACK_FEATURE_NAME,
-              savedSpaceSetting);
-    }
-
-  }
-
- 
-  /** The actual method for testing. */
-  public void testWithfeat(String nameAnnSets, String nameAnnType, String 
nameAnnFeat, Corpus data, boolean isUsingMajority) {
-    //  get the annotation sets
-    String [] annSetsN = nameAnnSets.split(";");
-    int numJudges = annSetsN.length;
-    int numDocs = data.size();
-    AnnotationSet[][] annArr2 = new AnnotationSet[numDocs][numJudges];
-    for(int i = 0; i < numDocs; ++i) {
-      Document doc = data.get(i);
-      for(int j=0; j<numJudges; ++j) {
-        // Get the annotation
-        annArr2[i][j] = doc.getAnnotations(annSetsN[j]).get(nameAnnType);
-      }
-    }
-    //Annotation merging
-    boolean isTheSameInstances = true;
-    for(int i=0; i<annArr2.length; ++i)
-      if(!AnnotationMerging.isSameInstancesForAnnotators(annArr2[i], 1)) {
-        isTheSameInstances = false;
-        break;
-      }
-    HashMap<Annotation,String>mergeInfor = new HashMap<Annotation,String>();
-    if(isUsingMajority)
-      AnnotationMerging.mergeAnnotationMajority(annArr2[0], nameAnnFeat, 
mergeInfor, isTheSameInstances);
-    else AnnotationMerging.mergeAnnotation(annArr2[0], nameAnnFeat, 
mergeInfor, 2, isTheSameInstances);
-    int numAnns=0;
-    if(isTheSameInstances) {
-      for(Annotation ann:mergeInfor.keySet()) {
-        if(ann.getFeatures().get(nameAnnFeat) != null)
-          ++numAnns;
-         
-      }
-    } else {
-      numAnns = mergeInfor.size();
-    }
-    checkNumbers(numAnns);
-  }
-
-  /** Check the numbers. */
-  private void checkNumbers(int numAnns) {
-    switch(caseN) {
-      case 1:
-        assertEquals(numAnns, 9);
-        break;
-      case 2:
-        assertEquals(numAnns, 9);
-        break;
-      case 3:
-        assertEquals(numAnns, 2);
-        break;
-      case 4:
-        assertEquals(numAnns, 2);
-        break;
-      default:
-        System.out.println("The test case " + caseN + " is not defined yet.");
-    }
-  }
-
-}

Deleted: 
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestClassificationMeasures.java
===================================================================
--- 
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestClassificationMeasures.java
        2016-10-04 05:35:22 UTC (rev 19621)
+++ 
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestClassificationMeasures.java
        2016-10-04 07:15:52 UTC (rev 19622)
@@ -1,92 +0,0 @@
-package gate.util;
-
-import gate.AnnotationSet;
-import gate.Document;
-import gate.Factory;
-import gate.Gate;
-import gate.corpora.TestDocument;
-
-import java.util.ArrayList;
-import java.net.URL;
-import junit.framework.Test;
-import junit.framework.TestCase;
-import junit.framework.TestSuite;
-
-public class TestClassificationMeasures extends TestCase{
-
-  /** Test suite routine for the test runner */
-  public static Test suite() {
-    return new TestSuite(TestClassificationMeasures.class);
-  } // suite
-
-  
-  @Override
-  protected void setUp() throws Exception {
-    // TODO Auto-generated method stub
-    super.setUp();
-  }
-
-  @Override
-  protected void tearDown() throws Exception {
-    // TODO Auto-generated method stub
-    super.tearDown();
-  }
- 
-  public void test(){
-    String type = "sent";
-    String feature = "Op";
-        
-    Document doc1 = null;
-    Document doc2 = null;
-    Document doc3 = null;
-    Document doc4 = null;
-        
-    try {
-      Gate.init();
-      
-      doc1 = Factory.newDocument(new 
URL(TestDocument.getTestServerName()+"tests/iaa/beijing-opera.xml"));
-      doc2 = Factory.newDocument(new 
URL(TestDocument.getTestServerName()+"tests/iaa/beijing-opera.xml"));
-      doc3 = Factory.newDocument(new 
URL(TestDocument.getTestServerName()+"tests/iaa/in-outlook-09-aug-2001.xml"));
-      doc4 = Factory.newDocument(new 
URL(TestDocument.getTestServerName()+"tests/iaa/in-outlook-09-aug-2001.xml"));
-        
-    } catch (Exception e) {
-      e.printStackTrace();
-    }
-    
-    if(doc1!=null && doc2!=null && doc3!=null && doc4!=null){
-      AnnotationSet as1 = doc1.getAnnotations("ann1");
-      AnnotationSet as2 = doc2.getAnnotations("ann2");
-
-      ClassificationMeasures myClassificationMeasures1 =
-        new ClassificationMeasures();
-      myClassificationMeasures1.calculateConfusionMatrix(
-        as1, as2, type, feature, true);
-      assertEquals(myClassificationMeasures1.getObservedAgreement(), 
0.7777778f);
-      assertEquals(myClassificationMeasures1.getKappaCohen(), 0.6086957f);
-      assertEquals(myClassificationMeasures1.getKappaPi(), 0.59550565f);
-      
-      AnnotationSet as3 = doc3.getAnnotations("ann1");
-      AnnotationSet as4 = doc4.getAnnotations("ann2");
-       
-      ClassificationMeasures myClassificationMeasures2 =
-        new ClassificationMeasures();
-      myClassificationMeasures2.calculateConfusionMatrix(
-        as3, as4, type, feature, true);
-      assertEquals(myClassificationMeasures2.getObservedAgreement(), 0.96875f);
-      assertEquals(myClassificationMeasures2.getKappaCohen(), 0.3263158f);
-      assertEquals(myClassificationMeasures2.getKappaPi(), 0.3227513f);
-       
-      ArrayList<ClassificationMeasures> tablesList = new 
ArrayList<ClassificationMeasures>();
-      tablesList.add(myClassificationMeasures1);
-      tablesList.add(myClassificationMeasures2);
-      ClassificationMeasures myNewClassificationMeasures =
-        new ClassificationMeasures(tablesList);
-      assertEquals(myNewClassificationMeasures.getObservedAgreement(), 
0.94520545f);
-      assertEquals(myNewClassificationMeasures.getKappaCohen(), 0.7784521f);
-      assertEquals(myNewClassificationMeasures.getKappaPi(), 0.7778622f);
-       
-    } else {
-      System.out.println("Failed to create docs from URLs.");
-    }
-  }
-}

Deleted: 
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestDiffer.java
===================================================================
--- 
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestDiffer.java    
    2016-10-04 05:35:22 UTC (rev 19621)
+++ 
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestDiffer.java    
    2016-10-04 07:15:52 UTC (rev 19622)
@@ -1,129 +0,0 @@
-/*
- *
- *  Copyright (c) 1995-2012, The University of Sheffield. See the file
- *  COPYRIGHT.txt in the software or at http://gate.ac.uk/gate/COPYRIGHT.txt
- *
- *  This file is part of GATE (see http://gate.ac.uk/), and is free
- *  software, licenced under the GNU Library General Public License,
- *  Version 2, June 1991 (in the distribution as file licence.html,
- *  and also available at http://gate.ac.uk/gate/licence.html).
- *
- *  Valentin Tablan, 26/Feb/2002
- *
- *  $Id$
- */
-
-package gate.util;
-
-import gate.Annotation;
-import gate.AnnotationSet;
-import gate.Document;
-import gate.Factory;
-import gate.FeatureMap;
-
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.List;
-
-import org.junit.Assert;
-import junit.framework.Test;
-import junit.framework.TestCase;
-import junit.framework.TestSuite;
-
-public class TestDiffer extends TestCase{
-  /** Construction */
-  public TestDiffer(String name) { super(name); }
-
-  /** Fixture set up */
-   @Override
-  public void setUp() {
-   } // setUp
-
-   /** Put things back as they should be after running tests.
-     */
-   @Override
-  public void tearDown() throws Exception {
-   } // tearDown
-
-   /** Test suite routine for the test runner */
-   public static Test suite() {
-     return new TestSuite(TestDiffer.class);
-   } // suite
-
-  /** Jdk compiler */
-   public void testDiffer() throws Exception {
-     Document doc = Factory.newDocument(
-         new URL(gate.corpora.TestDocument.getTestServerName() +
-                 "tests/ft-bt-03-aug-2001.html"),
-         "windows-1252"
-         );
-     AnnotationSet annSet = doc.getAnnotations();
-     //create 100 annotations
-     FeatureMap features = Factory.newFeatureMap();
-     features.put("type", "BAR");
-     for (int i = 0; i < 100; i++) {
-       annSet.add(new Long(i * 10), new Long( (i + 1) * 10), "Foo", features);
-     }
-     List<Annotation> keySet = new ArrayList<Annotation>(annSet);
-     List<Annotation> responseSet = new ArrayList<Annotation>(annSet);
-
-     //check 100% Precision and recall
-     AnnotationDiffer differ = new AnnotationDiffer();
-     differ.setSignificantFeaturesSet(null);
-     differ.calculateDiff(keySet, responseSet);
-     differ.sanityCheck();
-     if(DEBUG) differ.printMissmatches();
-     double value = differ.getPrecisionStrict();
-     Assert.assertEquals("Precision Strict: " + value + " instead of 1!",
-                         1, value, 0);
-     value = differ.getRecallStrict();
-     Assert.assertEquals("Recall Strict: " + value + " instead of 1!",
-                         1, value, 0);
-     value = differ.getPrecisionLenient();
-     Assert.assertEquals("Precision Lenient: " + value + " instead of 1!",
-                         1, value, 0);
-     value = differ.getRecallLenient();
-     Assert.assertEquals("Recall Lenient: " + value + " instead of 1!",
-                         1, value, 0);
-
-     //check low precision
-     Integer id = annSet.add(new Long(2), new Long(4), "Foo", features);
-     Annotation falsePositive = annSet.get(id);
-     responseSet.add(falsePositive);
-     differ.calculateDiff(keySet, responseSet);
-     differ.sanityCheck();
-     if(DEBUG) differ.printMissmatches();
-     value = differ.getPrecisionStrict();
-     Assert.assertEquals("Precision Strict: " + value + " instead of .99!",
-                         .99, value, .001);
-     //recall should still be 100%
-     value = differ.getRecallStrict();
-     Assert.assertEquals("Recall Strict: " + value + " instead of 1!",
-                         1, value, 0);
-     value = differ.getRecallLenient();
-     Assert.assertEquals("Recall Lenient: " + value + " instead of 1!",
-                         1, value, 0);
-
-
-     //check low recall
-     responseSet.remove(falsePositive);
-     keySet.add(falsePositive);
-     differ.calculateDiff(keySet, responseSet);
-     differ.sanityCheck();
-     if(DEBUG) differ.printMissmatches();
-     value = differ.getRecallStrict();
-     Assert.assertEquals("Recall Strict: " + value + " instead of .99!",
-                         .99, value, .001);
-     //precision should still be 100%
-     value = differ.getPrecisionStrict();
-     Assert.assertEquals("Precision Strict: " + value + " instead of 1!",
-                         1, value, 0);
-     value = differ.getPrecisionLenient();
-     Assert.assertEquals("Precision Lenient: " + value + " instead of 1!",
-                         1, value, 0);
-   }
-
-   /** Debug flag */
-   private static final boolean DEBUG = false;
-
-}
\ No newline at end of file

Deleted: 
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestFeatureMap.java
===================================================================
--- 
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestFeatureMap.java
    2016-10-04 05:35:22 UTC (rev 19621)
+++ 
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestFeatureMap.java
    2016-10-04 07:15:52 UTC (rev 19622)
@@ -1,134 +0,0 @@
-package gate.util;
-
-import junit.framework.*;
-
-/**
- * Title:        Gate2
- * Description:
- * Copyright:    Copyright (c) 2000
- * Company:      University Of Sheffield
- * @version 1.0
- */
-
-public class TestFeatureMap extends TestCase {
-
-    /** Construction */
-    public TestFeatureMap(String name) { super(name); }
-
-    /** Test the testPutAndGet()... methods. */
-    public void testPutAndGet() throws Exception {
-        assertTrue(true);
-        SimpleFeatureMapImpl map = new SimpleFeatureMapImpl();
-        map.put("1", "bala");
-        map.put("1", "bala2");
-        map.put("2", "20");
-        map.put("3", null);
-        map.put(null, "5");
-
-        Object value = null;
-        /**
-         * test1:
-         *      get replaced value by normal key
-         */
-        value = map.get("1");
-        assertSame(value, "bala2");
-        /**
-         * test 2:
-         *      get normal value by normal key
-         */
-        value = map.get("2");
-        assertSame(value, "20");
-        /**
-         * Test 3:
-         *      get null value by the key
-         */
-        value = map.get("3");
-        assertSame(value, null);
-        /**
-         * test 4:
-         *      try to get value by 'null' key
-         */
-        value = map.get(null);
-        assertSame(value, "5");
-    } // testPutAndGet()
-
-    public void testSubsume() throws Exception {
-        assertTrue(true);
-        SimpleFeatureMapImpl map = new SimpleFeatureMapImpl();
-        SimpleFeatureMapImpl map2 = new SimpleFeatureMapImpl();
-        map.put("1", "bala");
-        map2.put("1", map.get("1"));
-
-        map.put("2", "20");
-        /**
-         * test1:
-         *      subsume partially - map1 and map2 has one common element
-         */
-         assertTrue(map.subsumes(map2));
-        /**
-         * test 2:
-         *      map2 do NOT subsumes map1
-         */
-         assertTrue(!map2.subsumes(map));
-        /**
-         * Test 3:
-         *      subsume partially - map1 and map2.keySet()
-         */
-         assertTrue(map.subsumes(map2, map2.keySet()));
-        /**
-         * test 4:
-         *      map2 SUBSUMES and map using the map2.keySet()
-         */
-         assertTrue(map2.subsumes(map, map2.keySet()));
-
-        /**
-         * test 5,6,7,8:
-         *      test1,2,3,4 with NULL's in the map and
-         *      not NULL's the map2 under the same key "3"
-         */
-         map.put("3", null);
-         map2.put("3", "not null");
-
-         assertTrue(!map.subsumes(map2));
-         assertTrue(!map2.subsumes(map));
-         assertTrue(!map.subsumes(map2, map2.keySet()));
-         assertTrue(!map2.subsumes(map, map2.keySet()));
-
-         /**
-          * Test 9,10,11,12 repeat the same test but with compatible (null) 
values
-          * under the same key "3"
-          */
-         map2.put("3", null);
-
-         assertTrue(map.subsumes(map2));
-         assertTrue(!map2.subsumes(map));
-         assertTrue(map.subsumes(map2, map2.keySet()));
-         assertTrue(map2.subsumes(map, map2.keySet()));
-
-         /**
-          * Test 13,14,15,16 repeat the same test but with null keys in the 
two of the maps
-          */
-         map.put(null, "5");
-         map2.put(null, "5");
-
-         assertTrue(map.subsumes(map2));
-         assertTrue(!map2.subsumes(map));
-         assertTrue(map.subsumes(map2, map2.keySet()));
-         assertTrue(map2.subsumes(map, map2.keySet()));
-    } // testSubsume()
-
-    /** Test suite routine for the test runner */
-    public static Test suite() {
-        return new TestSuite(TestFeatureMap.class);
-    } // suite
-
-    public static void main(String args[]){
-        TestFeatureMap app = new TestFeatureMap("TestFeatureMap");
-        try {
-            app.testPutAndGet();
-            app.testSubsume();
-        } catch (Exception e) {
-            e.printStackTrace (Err.getPrintWriter());
-        }
-    } // main
-} // TestFeatureMap
\ No newline at end of file

Deleted: 
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestRBTreeMap.java
===================================================================
--- 
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestRBTreeMap.java 
    2016-10-04 05:35:22 UTC (rev 19621)
+++ 
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestRBTreeMap.java 
    2016-10-04 07:15:52 UTC (rev 19622)
@@ -1,159 +0,0 @@
-/*
- *  TestRBTreeMap.java
- *
- *  Copyright (c) 1995-2012, The University of Sheffield. See the file
- *  COPYRIGHT.txt in the software or at http://gate.ac.uk/gate/COPYRIGHT.txt
- *
- *  This file is part of GATE (see http://gate.ac.uk/), and is free
- *  software, licenced under the GNU Library General Public License,
- *  Version 2, June 1991 (in the distribution as file licence.html,
- *  and also available at http://gate.ac.uk/gate/licence.html).
- *  
- *  Valentin Tablan, 09/02/2000
- *
- *  $Id$
- */
-
-package gate.util;
-
-import junit.framework.*;
-
-/** Tests for the RBTreeMap class
-  */
-public class TestRBTreeMap extends TestCase
-{
-
-  /** Construction */
-  public TestRBTreeMap(String name) { super(name); }
-
-  /** Create a map  with sparse values as keys */
-  @Override
-  public void setUp() {
-    myTree=new RBTreeMap<Object,Object>();
-    myTree.put(new Long(10),"Ten");
-    myTree.put(new Long(20),"Twenty");
-    myTree.put(new Long(30),"Thirty");
-    myTree.put(new Long(40),"Forty");
-    myTree.put(new Long(50),"Fifty");
-  } // setUp
-
-  /** A test test */
-  public void testExact() {
-    Object result;
-    Long key;
-    String expected;
-
-    //try the first entry
-    key=new Long(10);
-    expected="Ten";
-    result=myTree.get(key);
-    assertEquals(expected,result);
-
-    //try some entry
-    key=new Long(30);
-    expected="Thirty";
-    result=myTree.get(key);
-    assertEquals(expected,result);
-
-    //try the last entry
-    key=new Long(50);
-    expected="Fifty";
-    result=myTree.get(key);
-    assertEquals(expected,result);
-
-    //try the last entry
-    key=new Long(15);
-    result=myTree.get(key);
-    assertNull(result);
-
-  } // testExact
-
-  public void testClosestMatch(){
-    Object[] result;
-    Long key;
-    Object[] expected;
-
-    //try a match
-    key=new Long(10);
-    expected=new Object[]{"Ten","Ten"};
-    result=myTree.getClosestMatch(key);
-    assertEquals("TestCM 1",expected[0],result[0]);
-    assertEquals("TestCM 2",expected[1],result[1]);
-
-    //try glb=null
-    key=new Long(5);
-    expected=new Object[]{null,"Ten"};
-    result=myTree.getClosestMatch(key);
-    assertNull("TestCM 3",result[0]);
-    assertEquals("TestCM 4",expected[1],result[1]);
-
-    //the normal case
-    key=new Long(15);
-    expected=new Object[]{"Ten","Twenty"};
-    result=myTree.getClosestMatch(key);
-    assertEquals("TestCM 5",expected[0],result[0]);
-    assertEquals("TestCM 6",expected[1],result[1]);
-
-    //try lub=null
-    key=new Long(55);
-    expected=new Object[]{"Fifty",null};
-    result=myTree.getClosestMatch(key);
-    assertEquals("TestCM 7",expected[0],result[0]);
-    assertNull("TestCM 8",result[1]);
-
-    //empty the tree
-    myTree=new RBTreeMap<Object,Object>();
-
-    //try glb=lub=null
-    key=new Long(15);
-    expected=new Object[]{null,null};
-    result=myTree.getClosestMatch(key);
-    assertNull("TestCM 9",result[0]);
-    assertNull("TestCM 10",result[1]);
-  }
-
-  public void testGetNextOf(){
-    Object result;
-    Long key;
-    String expected;
-
-    //try the first entry
-    key=new Long(5);
-    expected="Ten";
-    result=myTree.getNextOf(key);
-    assertEquals(expected,result);
-
-    //try some entry
-    key=new Long(20);
-    expected="Twenty";
-    result=myTree.getNextOf(key);
-    assertEquals(expected,result);
-
-    //try the "next" case
-    key=new Long(15);
-    expected="Twenty";
-    result=myTree.getNextOf(key);
-    assertEquals(expected,result);
-
-    //try the last case
-    key=new Long(55);
-    result=myTree.getNextOf(key);
-    assertNull(result);
-
-    //empty the tree
-    myTree=new RBTreeMap<Object,Object>();
-    key=new Long(15);
-    result=myTree.getNextOf(key);
-    assertNull(result);
-  }
-
-
-  /** Test suite routine for the test runner */
-  public static Test suite() {
-    return new TestSuite(TestRBTreeMap.class);
-  } // suite
-
-
-  private RBTreeMap<Object,Object> myTree;
-  
-} // class TestRBTreeMap

Deleted: 
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestTools.java
===================================================================
--- gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestTools.java 
2016-10-04 05:35:22 UTC (rev 19621)
+++ gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestTools.java 
2016-10-04 07:15:52 UTC (rev 19622)
@@ -1,146 +0,0 @@
-package gate.util;
-
-import java.lang.reflect.Constructor;
-
-import junit.framework.Test;
-import junit.framework.TestCase;
-import junit.framework.TestSuite;
-
-/**
- * Test cases for {@link Tools#getMostSpecificConstructor}.
- */
-public class TestTools extends TestCase {
-
-  public TestTools(String name) {
-    super(name);
-  }
-
-  // A small hierarchy of interfaces and classes to test
-  // getMostSpecificConstructor
-  private static interface InterfaceA {
-  }
-
-  private static interface InterfaceB {
-  }
-
-  private static interface SubInterfaceB extends InterfaceB {
-  }
-
-  @SuppressWarnings("unused")
-  private static class ClassA implements InterfaceA {
-  }
-
-  private static class ClassB implements InterfaceB {
-  }
-
-  private static class ClassSubB implements SubInterfaceB {
-  }
-
-  private static class ClassAB implements InterfaceA, InterfaceB {
-  }
-
-  private static class SubClassOfAB extends ClassAB {
-  }
-
-  private static class DifferentClassAB implements InterfaceA, InterfaceB {
-  }
-
-  @SuppressWarnings("unused")
-  private static class ConstructorTest {
-    
-    public ConstructorTest(InterfaceA a) {
-      // applicable to InterfaceA, ClassA, ClassAB, SubClassOfAB
-      // and DifferentClassAB
-    }
-
-    public ConstructorTest(InterfaceB b) {
-      // applicable to InterfaceB, ClassB, SubInterfaceB, ClassSubB,
-      // ClassAB, SubClassOfAB and DifferentClassAB
-    }
-
-    public ConstructorTest(SubInterfaceB sb) {
-      // applicable to SubInterfaceB and ClassSubB only
-    }
-
-    public ConstructorTest(ClassAB ab) {
-      // applicable to ClassAB and SubClassOfAB only
-    }
-  }
-
-  public void testGetMostSpecificConstructor1() throws Exception {
-    // simple case - there is only one constructor of
-    // ConstructorTest that is applicable to an argument of type ClassB
-    // - the one taking an InterfaceB
-    Constructor<?> expected =
-            ConstructorTest.class.getConstructor(InterfaceB.class);
-
-    Constructor<?> result =
-            Tools.getMostSpecificConstructor(ConstructorTest.class,
-                    ClassB.class);
-    assertEquals("Most specific constructor for ConstructorTest taking a "
-            + "ClassB should be ConstructorTest(InterfaceB)", expected, 
result);
-  }
-
-  public void testGetMostSpecificConstructor2() throws Exception {
-    // more complex case - there are two applicable constructors taking
-    // a ClassSubB - InterfaceB and SubInterfaceB - but the latter is
-    // more specific than the former
-    Constructor<?> expected =
-            ConstructorTest.class.getConstructor(SubInterfaceB.class);
-
-    Constructor<?> result =
-            Tools.getMostSpecificConstructor(ConstructorTest.class,
-                    ClassSubB.class);
-    assertEquals("Most specific constructor for ConstructorTest taking a "
-            + "ClassSubB should be ConstructorTest(SubInterfaceB)", expected,
-            result);
-  }
-
-  public void testGetMostSpecificConstructor3() throws Exception {
-    // more complex again - there are three applicable constructors
-    // taking a SubClassOfAB - InterfaceA, InterfaceB and ClassAB - but
-    // the last is more specific than both the others, so should
-    // be chosen
-    Constructor<?> expected = 
ConstructorTest.class.getConstructor(ClassAB.class);
-
-    Constructor<?> result =
-            Tools.getMostSpecificConstructor(ConstructorTest.class,
-                    SubClassOfAB.class);
-    assertEquals("Most specific constructor for ConstructorTest taking a "
-            + "SubClassOfAB should be ConstructorTest(ClassAB)", expected,
-            result);
-  }
-
-  public void testGetMostSpecificConstructor4() throws Exception {
-    // ambiguous case - there are two applicable constructors for
-    // a DifferentClassAB - InterfaceA and InterfaceB - and neither
-    // is more specific than the other. We expect an "ambiguous"
-    // exception
-
-    try {
-      Tools.getMostSpecificConstructor(ConstructorTest.class,
-                      DifferentClassAB.class);
-    }
-    catch(NoSuchMethodException e) {
-      assertTrue("Expected \"ambiguous\" exception", e.getMessage().startsWith(
-              "Ambiguous"));
-      return;
-    }
-
-    fail("getMostSpecificConstructor(ConstructorTest, "
-            + "DifferentClassAB) "
-            + "should have thrown an exception");
-  }
-
-  public static Test suite() {
-    return new TestSuite(TestTools.class);
-  }
-
-  public static void main(String[] argv) throws Exception {
-    TestTools app = new TestTools("TestTools");
-    app.testGetMostSpecificConstructor1();
-    app.testGetMostSpecificConstructor2();
-    app.testGetMostSpecificConstructor3();
-    app.testGetMostSpecificConstructor4();
-  }
-}

Modified: gate/branches/sawdust2/gate-core/src/test/java/gate/html/TestHtml.java
===================================================================
--- gate/branches/sawdust2/gate-core/src/test/java/gate/html/TestHtml.java      
2016-10-04 05:35:22 UTC (rev 19621)
+++ gate/branches/sawdust2/gate-core/src/test/java/gate/html/TestHtml.java      
2016-10-04 07:15:52 UTC (rev 19622)
@@ -16,23 +16,18 @@
 
 package gate.html;
 
+import java.net.URL;
+
 import gate.Gate;
 import gate.corpora.MimeType;
 import gate.corpora.TestDocument;
-
-import java.net.URL;
-
-import junit.framework.Test;
 import junit.framework.TestCase;
-import junit.framework.TestSuite;
 
 
 /** Test class for HTML facilities
   */
 public class TestHtml extends TestCase
 {
-  /** Construction */
-  public TestHtml(String name) { super(name); }
 
   /** Fixture set up */
   @Override
@@ -88,19 +83,6 @@
 */
   } // testUnpackMarkup()
 //*
-  public static void main(String[] args){
-    try{
-      Gate.init();
-      TestHtml test = new TestHtml("gicu");
-      test.testUnpackMarkup();
-    } catch (Exception e){
-      e.printStackTrace(System.out);
-    }
-  }
-//*/
-  /** Test suite routine for the test runner */
-  public static Test suite() {
-    return new TestSuite(TestHtml.class);
-  } // suite
 
+
 }//class TestHtml

Copied: 
gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestAnnotationMerging.java
 (from rev 19621, 
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestAnnotationMerging.java)
===================================================================
--- 
gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestAnnotationMerging.java
                         (rev 0)
+++ 
gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestAnnotationMerging.java
 2016-10-04 07:15:52 UTC (rev 19622)
@@ -0,0 +1,159 @@
+package gate.util;
+
+import java.net.URL;
+import java.util.HashMap;
+
+import gate.Annotation;
+import gate.AnnotationSet;
+import gate.Corpus;
+import gate.Document;
+import gate.Factory;
+import gate.Gate;
+import gate.GateConstants;
+import gate.corpora.TestDocument;
+import junit.framework.TestCase;
+
+public class TestAnnotationMerging extends TestCase {
+  /** The id of test case. */
+  int caseN;
+
+  /** Fixture set up */
+  @Override
+  public void setUp() throws Exception {
+    if (!Gate.isInitialised()) {
+      Gate.runInSandbox(true);
+      Gate.init();
+    }
+  } // setUp
+
+  /**
+   * Put things back as they should be after running tests.
+   */
+  @Override
+  public void tearDown() throws Exception {
+  } // tearDown
+
+  private Document loadDocument(String path, String name) throws Exception {
+    Document doc = Factory.newDocument(new 
URL(TestDocument.getTestServerName()+path), "UTF-8");
+    doc.setName(name);
+    return doc;
+  }
+
+  /** The test for AnnotationMerging. */
+  public void testAnnotationMerging() throws Exception {
+
+    Boolean savedSpaceSetting = Gate.getUserConfig().getBoolean(
+            GateConstants.DOCUMENT_ADD_SPACE_ON_UNPACK_FEATURE_NAME);
+    Gate.getUserConfig().put(
+            GateConstants.DOCUMENT_ADD_SPACE_ON_UNPACK_FEATURE_NAME,
+            Boolean.FALSE);
+    try {
+
+      //Gate.setGateHome(new File("C:\\svn\\gate"));
+      //Gate.setUserConfigFile(new File("C:\\svn\\gate.xml"));
+      //Gate.init();
+      // Load the documents into a corpus
+      Corpus data = Factory.newCorpus("data");
+      // Put the annotated document into a matrix for IAA
+      String nameAnnSet;
+      String nameAnnType = "";
+      String nameAnnFeat = "";
+      // Use the dataset of one document and three annotators
+      data.add(loadDocument("tests/iaa/beijing-opera.xml", 
"beijing-opera.xml"));
+      //ExtensionFileFilter fileFilter = new ExtensionFileFilter();
+      //fileFilter.addExtension("xml");
+      //data.populate(new 
File("C:\\yaoyong_h\\work\\iaa\\data\\smallData").toURI().toURL(), fileFilter, 
"UTF-8", false);
+      
+      nameAnnSet = "ann1;ann2;ann3";
+      boolean isUsingMajority=false;
+      nameAnnType = "sent";
+      nameAnnFeat = "Op";
+      caseN = 1;
+      isUsingMajority=true;
+      testWithfeat(nameAnnSet, nameAnnType, nameAnnFeat,
+              data, isUsingMajority);
+      
+      caseN = 2;
+      isUsingMajority=false;
+      testWithfeat(nameAnnSet, nameAnnType, nameAnnFeat,
+              data, isUsingMajority);
+
+      
+      nameAnnType = "Os";
+      nameAnnFeat = null;
+      caseN = 3;
+      isUsingMajority=true;
+      testWithfeat(nameAnnSet, nameAnnType, nameAnnFeat, data, 
isUsingMajority);
+      
+      caseN = 4;
+      isUsingMajority=false;
+      testWithfeat(nameAnnSet, nameAnnType, nameAnnFeat, data, 
isUsingMajority);
+    }
+    finally {
+      Gate.getUserConfig().put(
+              GateConstants.DOCUMENT_ADD_SPACE_ON_UNPACK_FEATURE_NAME,
+              savedSpaceSetting);
+    }
+
+  }
+
+ 
+  /** The actual method for testing. */
+  public void testWithfeat(String nameAnnSets, String nameAnnType, String 
nameAnnFeat, Corpus data, boolean isUsingMajority) {
+    //  get the annotation sets
+    String [] annSetsN = nameAnnSets.split(";");
+    int numJudges = annSetsN.length;
+    int numDocs = data.size();
+    AnnotationSet[][] annArr2 = new AnnotationSet[numDocs][numJudges];
+    for(int i = 0; i < numDocs; ++i) {
+      Document doc = data.get(i);
+      for(int j=0; j<numJudges; ++j) {
+        // Get the annotation
+        annArr2[i][j] = doc.getAnnotations(annSetsN[j]).get(nameAnnType);
+      }
+    }
+    //Annotation merging
+    boolean isTheSameInstances = true;
+    for(int i=0; i<annArr2.length; ++i)
+      if(!AnnotationMerging.isSameInstancesForAnnotators(annArr2[i], 1)) {
+        isTheSameInstances = false;
+        break;
+      }
+    HashMap<Annotation,String>mergeInfor = new HashMap<Annotation,String>();
+    if(isUsingMajority)
+      AnnotationMerging.mergeAnnotationMajority(annArr2[0], nameAnnFeat, 
mergeInfor, isTheSameInstances);
+    else AnnotationMerging.mergeAnnotation(annArr2[0], nameAnnFeat, 
mergeInfor, 2, isTheSameInstances);
+    int numAnns=0;
+    if(isTheSameInstances) {
+      for(Annotation ann:mergeInfor.keySet()) {
+        if(ann.getFeatures().get(nameAnnFeat) != null)
+          ++numAnns;
+         
+      }
+    } else {
+      numAnns = mergeInfor.size();
+    }
+    checkNumbers(numAnns);
+  }
+
+  /** Check the numbers. */
+  private void checkNumbers(int numAnns) {
+    switch(caseN) {
+      case 1:
+        assertEquals(numAnns, 9);
+        break;
+      case 2:
+        assertEquals(numAnns, 9);
+        break;
+      case 3:
+        assertEquals(numAnns, 2);
+        break;
+      case 4:
+        assertEquals(numAnns, 2);
+        break;
+      default:
+        System.out.println("The test case " + caseN + " is not defined yet.");
+    }
+  }
+
+}

Copied: 
gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestClassificationMeasures.java
 (from rev 19621, 
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestClassificationMeasures.java)
===================================================================
--- 
gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestClassificationMeasures.java
                            (rev 0)
+++ 
gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestClassificationMeasures.java
    2016-10-04 07:15:52 UTC (rev 19622)
@@ -0,0 +1,80 @@
+package gate.util;
+
+import java.net.URL;
+import java.util.ArrayList;
+
+import gate.AnnotationSet;
+import gate.Document;
+import gate.Factory;
+import gate.Gate;
+import gate.corpora.TestDocument;
+import junit.framework.TestCase;
+
+public class TestClassificationMeasures extends TestCase{
+ 
+  @Override
+  public void setUp() throws Exception {
+    if (!Gate.isInitialised()) {
+      Gate.runInSandbox(true);
+      Gate.init();
+    }
+  }
+
+  public void test(){
+    String type = "sent";
+    String feature = "Op";
+        
+    Document doc1 = null;
+    Document doc2 = null;
+    Document doc3 = null;
+    Document doc4 = null;
+        
+    try {
+      Gate.init();
+      
+      doc1 = Factory.newDocument(new 
URL(TestDocument.getTestServerName()+"tests/iaa/beijing-opera.xml"));
+      doc2 = Factory.newDocument(new 
URL(TestDocument.getTestServerName()+"tests/iaa/beijing-opera.xml"));
+      doc3 = Factory.newDocument(new 
URL(TestDocument.getTestServerName()+"tests/iaa/in-outlook-09-aug-2001.xml"));
+      doc4 = Factory.newDocument(new 
URL(TestDocument.getTestServerName()+"tests/iaa/in-outlook-09-aug-2001.xml"));
+        
+    } catch (Exception e) {
+      e.printStackTrace();
+    }
+    
+    if(doc1!=null && doc2!=null && doc3!=null && doc4!=null){
+      AnnotationSet as1 = doc1.getAnnotations("ann1");
+      AnnotationSet as2 = doc2.getAnnotations("ann2");
+
+      ClassificationMeasures myClassificationMeasures1 =
+        new ClassificationMeasures();
+      myClassificationMeasures1.calculateConfusionMatrix(
+        as1, as2, type, feature, true);
+      assertEquals(myClassificationMeasures1.getObservedAgreement(), 
0.7777778f);
+      assertEquals(myClassificationMeasures1.getKappaCohen(), 0.6086957f);
+      assertEquals(myClassificationMeasures1.getKappaPi(), 0.59550565f);
+      
+      AnnotationSet as3 = doc3.getAnnotations("ann1");
+      AnnotationSet as4 = doc4.getAnnotations("ann2");
+       
+      ClassificationMeasures myClassificationMeasures2 =
+        new ClassificationMeasures();
+      myClassificationMeasures2.calculateConfusionMatrix(
+        as3, as4, type, feature, true);
+      assertEquals(myClassificationMeasures2.getObservedAgreement(), 0.96875f);
+      assertEquals(myClassificationMeasures2.getKappaCohen(), 0.3263158f);
+      assertEquals(myClassificationMeasures2.getKappaPi(), 0.3227513f);
+       
+      ArrayList<ClassificationMeasures> tablesList = new 
ArrayList<ClassificationMeasures>();
+      tablesList.add(myClassificationMeasures1);
+      tablesList.add(myClassificationMeasures2);
+      ClassificationMeasures myNewClassificationMeasures =
+        new ClassificationMeasures(tablesList);
+      assertEquals(myNewClassificationMeasures.getObservedAgreement(), 
0.94520545f);
+      assertEquals(myNewClassificationMeasures.getKappaCohen(), 0.7784521f);
+      assertEquals(myNewClassificationMeasures.getKappaPi(), 0.7778622f);
+       
+    } else {
+      System.out.println("Failed to create docs from URLs.");
+    }
+  }
+}

Copied: 
gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestDiffer.java (from 
rev 19621, 
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestDiffer.java)
===================================================================
--- gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestDiffer.java    
                        (rev 0)
+++ gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestDiffer.java    
2016-10-04 07:15:52 UTC (rev 19622)
@@ -0,0 +1,124 @@
+/*
+ *
+ *  Copyright (c) 1995-2012, The University of Sheffield. See the file
+ *  COPYRIGHT.txt in the software or at http://gate.ac.uk/gate/COPYRIGHT.txt
+ *
+ *  This file is part of GATE (see http://gate.ac.uk/), and is free
+ *  software, licenced under the GNU Library General Public License,
+ *  Version 2, June 1991 (in the distribution as file licence.html,
+ *  and also available at http://gate.ac.uk/gate/licence.html).
+ *
+ *  Valentin Tablan, 26/Feb/2002
+ *
+ *  $Id$
+ */
+
+package gate.util;
+
+import java.net.URL;
+import java.util.ArrayList;
+import java.util.List;
+
+import org.junit.Assert;
+
+import gate.Annotation;
+import gate.AnnotationSet;
+import gate.Document;
+import gate.Factory;
+import gate.FeatureMap;
+import gate.Gate;
+import junit.framework.TestCase;
+
+public class TestDiffer extends TestCase{
+
+  /** Fixture set up */
+   @Override
+   public void setUp() throws Exception {
+     if (!Gate.isInitialised()) {
+       Gate.runInSandbox(true);
+       Gate.init();
+     }
+   } // setUp
+
+   /** Put things back as they should be after running tests.
+     */
+   @Override
+  public void tearDown() throws Exception {
+   } // tearDown
+
+   public void testDiffer() throws Exception {
+     Document doc = Factory.newDocument(
+         new URL(gate.corpora.TestDocument.getTestServerName() +
+                 "tests/ft-bt-03-aug-2001.html"),
+         "windows-1252"
+         );
+     AnnotationSet annSet = doc.getAnnotations();
+     //create 100 annotations
+     FeatureMap features = Factory.newFeatureMap();
+     features.put("type", "BAR");
+     for (int i = 0; i < 100; i++) {
+       annSet.add(new Long(i * 10), new Long( (i + 1) * 10), "Foo", features);
+     }
+     List<Annotation> keySet = new ArrayList<Annotation>(annSet);
+     List<Annotation> responseSet = new ArrayList<Annotation>(annSet);
+
+     //check 100% Precision and recall
+     AnnotationDiffer differ = new AnnotationDiffer();
+     differ.setSignificantFeaturesSet(null);
+     differ.calculateDiff(keySet, responseSet);
+     differ.sanityCheck();
+     if(DEBUG) differ.printMissmatches();
+     double value = differ.getPrecisionStrict();
+     Assert.assertEquals("Precision Strict: " + value + " instead of 1!",
+                         1, value, 0);
+     value = differ.getRecallStrict();
+     Assert.assertEquals("Recall Strict: " + value + " instead of 1!",
+                         1, value, 0);
+     value = differ.getPrecisionLenient();
+     Assert.assertEquals("Precision Lenient: " + value + " instead of 1!",
+                         1, value, 0);
+     value = differ.getRecallLenient();
+     Assert.assertEquals("Recall Lenient: " + value + " instead of 1!",
+                         1, value, 0);
+
+     //check low precision
+     Integer id = annSet.add(new Long(2), new Long(4), "Foo", features);
+     Annotation falsePositive = annSet.get(id);
+     responseSet.add(falsePositive);
+     differ.calculateDiff(keySet, responseSet);
+     differ.sanityCheck();
+     if(DEBUG) differ.printMissmatches();
+     value = differ.getPrecisionStrict();
+     Assert.assertEquals("Precision Strict: " + value + " instead of .99!",
+                         .99, value, .001);
+     //recall should still be 100%
+     value = differ.getRecallStrict();
+     Assert.assertEquals("Recall Strict: " + value + " instead of 1!",
+                         1, value, 0);
+     value = differ.getRecallLenient();
+     Assert.assertEquals("Recall Lenient: " + value + " instead of 1!",
+                         1, value, 0);
+
+
+     //check low recall
+     responseSet.remove(falsePositive);
+     keySet.add(falsePositive);
+     differ.calculateDiff(keySet, responseSet);
+     differ.sanityCheck();
+     if(DEBUG) differ.printMissmatches();
+     value = differ.getRecallStrict();
+     Assert.assertEquals("Recall Strict: " + value + " instead of .99!",
+                         .99, value, .001);
+     //precision should still be 100%
+     value = differ.getPrecisionStrict();
+     Assert.assertEquals("Precision Strict: " + value + " instead of 1!",
+                         1, value, 0);
+     value = differ.getPrecisionLenient();
+     Assert.assertEquals("Precision Lenient: " + value + " instead of 1!",
+                         1, value, 0);
+   }
+
+   /** Debug flag */
+   private static final boolean DEBUG = false;
+
+}
\ No newline at end of file

Copied: 
gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestFeatureMap.java 
(from rev 19621, 
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestFeatureMap.java)
===================================================================
--- 
gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestFeatureMap.java    
                            (rev 0)
+++ 
gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestFeatureMap.java    
    2016-10-04 07:15:52 UTC (rev 19622)
@@ -0,0 +1,122 @@
+package gate.util;
+
+import junit.framework.TestCase;
+
+/**
+ * Title:        Gate2
+ * Description:
+ * Copyright:    Copyright (c) 2000
+ * Company:      University Of Sheffield
+ * @version 1.0
+ */
+
+public class TestFeatureMap extends TestCase {
+    
+    @Override
+    public void setUp() throws Exception {
+    // we don't need to init GATE this time as we aren't actually using it for
+    // anything
+    }
+
+    /** Test the testPutAndGet()... methods. */
+    public void testPutAndGet() throws Exception {
+        assertTrue(true);
+        SimpleFeatureMapImpl map = new SimpleFeatureMapImpl();
+        map.put("1", "bala");
+        map.put("1", "bala2");
+        map.put("2", "20");
+        map.put("3", null);
+        map.put(null, "5");
+
+        Object value = null;
+        /**
+         * test1:
+         *      get replaced value by normal key
+         */
+        value = map.get("1");
+        assertSame(value, "bala2");
+        /**
+         * test 2:
+         *      get normal value by normal key
+         */
+        value = map.get("2");
+        assertSame(value, "20");
+        /**
+         * Test 3:
+         *      get null value by the key
+         */
+        value = map.get("3");
+        assertSame(value, null);
+        /**
+         * test 4:
+         *      try to get value by 'null' key
+         */
+        value = map.get(null);
+        assertSame(value, "5");
+    } // testPutAndGet()
+
+    public void testSubsume() throws Exception {
+        assertTrue(true);
+        SimpleFeatureMapImpl map = new SimpleFeatureMapImpl();
+        SimpleFeatureMapImpl map2 = new SimpleFeatureMapImpl();
+        map.put("1", "bala");
+        map2.put("1", map.get("1"));
+
+        map.put("2", "20");
+        /**
+         * test1:
+         *      subsume partially - map1 and map2 has one common element
+         */
+         assertTrue(map.subsumes(map2));
+        /**
+         * test 2:
+         *      map2 do NOT subsumes map1
+         */
+         assertTrue(!map2.subsumes(map));
+        /**
+         * Test 3:
+         *      subsume partially - map1 and map2.keySet()
+         */
+         assertTrue(map.subsumes(map2, map2.keySet()));
+        /**
+         * test 4:
+         *      map2 SUBSUMES and map using the map2.keySet()
+         */
+         assertTrue(map2.subsumes(map, map2.keySet()));
+
+        /**
+         * test 5,6,7,8:
+         *      test1,2,3,4 with NULL's in the map and
+         *      not NULL's the map2 under the same key "3"
+         */
+         map.put("3", null);
+         map2.put("3", "not null");
+
+         assertTrue(!map.subsumes(map2));
+         assertTrue(!map2.subsumes(map));
+         assertTrue(!map.subsumes(map2, map2.keySet()));
+         assertTrue(!map2.subsumes(map, map2.keySet()));
+
+         /**
+          * Test 9,10,11,12 repeat the same test but with compatible (null) 
values
+          * under the same key "3"
+          */
+         map2.put("3", null);
+
+         assertTrue(map.subsumes(map2));
+         assertTrue(!map2.subsumes(map));
+         assertTrue(map.subsumes(map2, map2.keySet()));
+         assertTrue(map2.subsumes(map, map2.keySet()));
+
+         /**
+          * Test 13,14,15,16 repeat the same test but with null keys in the 
two of the maps
+          */
+         map.put(null, "5");
+         map2.put(null, "5");
+
+         assertTrue(map.subsumes(map2));
+         assertTrue(!map2.subsumes(map));
+         assertTrue(map.subsumes(map2, map2.keySet()));
+         assertTrue(map2.subsumes(map, map2.keySet()));
+    } // testSubsume()
+} // TestFeatureMap
\ No newline at end of file

Copied: 
gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestRBTreeMap.java 
(from rev 19621, 
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestRBTreeMap.java)
===================================================================
--- gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestRBTreeMap.java 
                        (rev 0)
+++ gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestRBTreeMap.java 
2016-10-04 07:15:52 UTC (rev 19622)
@@ -0,0 +1,152 @@
+/*
+ *  TestRBTreeMap.java
+ *
+ *  Copyright (c) 1995-2012, The University of Sheffield. See the file
+ *  COPYRIGHT.txt in the software or at http://gate.ac.uk/gate/COPYRIGHT.txt
+ *
+ *  This file is part of GATE (see http://gate.ac.uk/), and is free
+ *  software, licenced under the GNU Library General Public License,
+ *  Version 2, June 1991 (in the distribution as file licence.html,
+ *  and also available at http://gate.ac.uk/gate/licence.html).
+ *  
+ *  Valentin Tablan, 09/02/2000
+ *
+ *  $Id$
+ */
+
+package gate.util;
+
+import junit.framework.TestCase;
+
+/** Tests for the RBTreeMap class
+  */
+public class TestRBTreeMap extends TestCase
+{
+
+  /** Create a map  with sparse values as keys */
+  @Override
+  public void setUp() {
+    
+    //we don't need to init GATE for this test
+    
+    myTree=new RBTreeMap<Object,Object>();
+    myTree.put(new Long(10),"Ten");
+    myTree.put(new Long(20),"Twenty");
+    myTree.put(new Long(30),"Thirty");
+    myTree.put(new Long(40),"Forty");
+    myTree.put(new Long(50),"Fifty");
+  } // setUp
+
+  /** A test test */
+  public void testExact() {
+    Object result;
+    Long key;
+    String expected;
+
+    //try the first entry
+    key=new Long(10);
+    expected="Ten";
+    result=myTree.get(key);
+    assertEquals(expected,result);
+
+    //try some entry
+    key=new Long(30);
+    expected="Thirty";
+    result=myTree.get(key);
+    assertEquals(expected,result);
+
+    //try the last entry
+    key=new Long(50);
+    expected="Fifty";
+    result=myTree.get(key);
+    assertEquals(expected,result);
+
+    //try the last entry
+    key=new Long(15);
+    result=myTree.get(key);
+    assertNull(result);
+
+  } // testExact
+
+  public void testClosestMatch(){
+    Object[] result;
+    Long key;
+    Object[] expected;
+
+    //try a match
+    key=new Long(10);
+    expected=new Object[]{"Ten","Ten"};
+    result=myTree.getClosestMatch(key);
+    assertEquals("TestCM 1",expected[0],result[0]);
+    assertEquals("TestCM 2",expected[1],result[1]);
+
+    //try glb=null
+    key=new Long(5);
+    expected=new Object[]{null,"Ten"};
+    result=myTree.getClosestMatch(key);
+    assertNull("TestCM 3",result[0]);
+    assertEquals("TestCM 4",expected[1],result[1]);
+
+    //the normal case
+    key=new Long(15);
+    expected=new Object[]{"Ten","Twenty"};
+    result=myTree.getClosestMatch(key);
+    assertEquals("TestCM 5",expected[0],result[0]);
+    assertEquals("TestCM 6",expected[1],result[1]);
+
+    //try lub=null
+    key=new Long(55);
+    expected=new Object[]{"Fifty",null};
+    result=myTree.getClosestMatch(key);
+    assertEquals("TestCM 7",expected[0],result[0]);
+    assertNull("TestCM 8",result[1]);
+
+    //empty the tree
+    myTree=new RBTreeMap<Object,Object>();
+
+    //try glb=lub=null
+    key=new Long(15);
+    expected=new Object[]{null,null};
+    result=myTree.getClosestMatch(key);
+    assertNull("TestCM 9",result[0]);
+    assertNull("TestCM 10",result[1]);
+  }
+
+  public void testGetNextOf(){
+    Object result;
+    Long key;
+    String expected;
+
+    //try the first entry
+    key=new Long(5);
+    expected="Ten";
+    result=myTree.getNextOf(key);
+    assertEquals(expected,result);
+
+    //try some entry
+    key=new Long(20);
+    expected="Twenty";
+    result=myTree.getNextOf(key);
+    assertEquals(expected,result);
+
+    //try the "next" case
+    key=new Long(15);
+    expected="Twenty";
+    result=myTree.getNextOf(key);
+    assertEquals(expected,result);
+
+    //try the last case
+    key=new Long(55);
+    result=myTree.getNextOf(key);
+    assertNull(result);
+
+    //empty the tree
+    myTree=new RBTreeMap<Object,Object>();
+    key=new Long(15);
+    result=myTree.getNextOf(key);
+    assertNull(result);
+  }
+
+  private RBTreeMap<Object,Object> myTree;
+  
+} // class TestRBTreeMap

Copied: gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestTools.java 
(from rev 19621, 
gate/branches/sawdust2/gate-core/src/test/disabled/gate/util/TestTools.java)
===================================================================
--- gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestTools.java     
                        (rev 0)
+++ gate/branches/sawdust2/gate-core/src/test/java/gate/util/TestTools.java     
2016-10-04 07:15:52 UTC (rev 19622)
@@ -0,0 +1,128 @@
+package gate.util;
+
+import java.lang.reflect.Constructor;
+
+import junit.framework.TestCase;
+
+/**
+ * Test cases for {@link Tools#getMostSpecificConstructor}.
+ */
+public class TestTools extends TestCase {
+
+  // A small hierarchy of interfaces and classes to test
+  // getMostSpecificConstructor
+  private static interface InterfaceA {
+  }
+
+  private static interface InterfaceB {
+  }
+
+  private static interface SubInterfaceB extends InterfaceB {
+  }
+
+  @SuppressWarnings("unused")
+  private static class ClassA implements InterfaceA {
+  }
+
+  private static class ClassB implements InterfaceB {
+  }
+
+  private static class ClassSubB implements SubInterfaceB {
+  }
+
+  private static class ClassAB implements InterfaceA, InterfaceB {
+  }
+
+  private static class SubClassOfAB extends ClassAB {
+  }
+
+  private static class DifferentClassAB implements InterfaceA, InterfaceB {
+  }
+
+  @SuppressWarnings("unused")
+  private static class ConstructorTest {
+    
+    public ConstructorTest(InterfaceA a) {
+      // applicable to InterfaceA, ClassA, ClassAB, SubClassOfAB
+      // and DifferentClassAB
+    }
+
+    public ConstructorTest(InterfaceB b) {
+      // applicable to InterfaceB, ClassB, SubInterfaceB, ClassSubB,
+      // ClassAB, SubClassOfAB and DifferentClassAB
+    }
+
+    public ConstructorTest(SubInterfaceB sb) {
+      // applicable to SubInterfaceB and ClassSubB only
+    }
+
+    public ConstructorTest(ClassAB ab) {
+      // applicable to ClassAB and SubClassOfAB only
+    }
+  }
+
+  public void testGetMostSpecificConstructor1() throws Exception {
+    // simple case - there is only one constructor of
+    // ConstructorTest that is applicable to an argument of type ClassB
+    // - the one taking an InterfaceB
+    Constructor<?> expected =
+            ConstructorTest.class.getConstructor(InterfaceB.class);
+
+    Constructor<?> result =
+            Tools.getMostSpecificConstructor(ConstructorTest.class,
+                    ClassB.class);
+    assertEquals("Most specific constructor for ConstructorTest taking a "
+            + "ClassB should be ConstructorTest(InterfaceB)", expected, 
result);
+  }
+
+  public void testGetMostSpecificConstructor2() throws Exception {
+    // more complex case - there are two applicable constructors taking
+    // a ClassSubB - InterfaceB and SubInterfaceB - but the latter is
+    // more specific than the former
+    Constructor<?> expected =
+            ConstructorTest.class.getConstructor(SubInterfaceB.class);
+
+    Constructor<?> result =
+            Tools.getMostSpecificConstructor(ConstructorTest.class,
+                    ClassSubB.class);
+    assertEquals("Most specific constructor for ConstructorTest taking a "
+            + "ClassSubB should be ConstructorTest(SubInterfaceB)", expected,
+            result);
+  }
+
+  public void testGetMostSpecificConstructor3() throws Exception {
+    // more complex again - there are three applicable constructors
+    // taking a SubClassOfAB - InterfaceA, InterfaceB and ClassAB - but
+    // the last is more specific than both the others, so should
+    // be chosen
+    Constructor<?> expected = 
ConstructorTest.class.getConstructor(ClassAB.class);
+
+    Constructor<?> result =
+            Tools.getMostSpecificConstructor(ConstructorTest.class,
+                    SubClassOfAB.class);
+    assertEquals("Most specific constructor for ConstructorTest taking a "
+            + "SubClassOfAB should be ConstructorTest(ClassAB)", expected,
+            result);
+  }
+
+  public void testGetMostSpecificConstructor4() throws Exception {
+    // ambiguous case - there are two applicable constructors for
+    // a DifferentClassAB - InterfaceA and InterfaceB - and neither
+    // is more specific than the other. We expect an "ambiguous"
+    // exception
+
+    try {
+      Tools.getMostSpecificConstructor(ConstructorTest.class,
+                      DifferentClassAB.class);
+    }
+    catch(NoSuchMethodException e) {
+      assertTrue("Expected \"ambiguous\" exception", e.getMessage().startsWith(
+              "Ambiguous"));
+      return;
+    }
+
+    fail("getMostSpecificConstructor(ConstructorTest, "
+            + "DifferentClassAB) "
+            + "should have thrown an exception");
+  }
+}

Copied: 
gate/branches/sawdust2/gate-core/src/test/resources/gate/resources/gate.ac.uk/tests/ft-bt-03-aug-2001.html
 (from rev 19599, 
gate/branches/sawdust2/plugins/ANNIE/src/test/resources/tests/ft-bt-03-aug-2001.html)
===================================================================
--- 
gate/branches/sawdust2/gate-core/src/test/resources/gate/resources/gate.ac.uk/tests/ft-bt-03-aug-2001.html
                          (rev 0)
+++ 
gate/branches/sawdust2/gate-core/src/test/resources/gate/resources/gate.ac.uk/tests/ft-bt-03-aug-2001.html
  2016-10-04 07:15:52 UTC (rev 19622)
@@ -0,0 +1,278 @@
+<!-- Vignette V/5 Mon Aug 06 07:50:01 2001 -->
+<SCRIPT LANGUAGE="javascript">
+    <!-- hide from old browsers
+    function goUrl(Selected) {
+           /* change page location to option selected from navigation 
drop-down */
+           var newURL = Selected.options[Selected.selectedIndex].value ;
+           if (newURL!=" ") {
+                   document.location.href = newURL;
+           }
+    }
+    // End of javascript -->
+</SCRIPT>
+<HTML>
+<HEAD>
+        <TITLE>Guardian Unlimited | Archive Search</TITLE>
+</HEAD>
+
+
+<BODY BGCOLOR="#FFFFFF" TOPMARGIN="8" LEFTMARGIN="0" LINK="#003366" 
VLINK="#003366" ALINK="#FF0000">
+
+<!-- Vignette V/5 Sun Aug 05 10:18:02 2001 -->
+
+<CENTER>
+<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" WIDTH="608">
+<!-- Row 1 - Logo + advertising -->
+<TR VALIGN="TOP">
+       <TD WIDTH="140" ALIGN=LEFT HEIGHT="68">
+               <!-- GU logo box and second box -->
+               <!-- Vignette V/5 Sun Aug 05 10:18:02 2001 -->
+<!-- logo box--><A HREF="/0,6961,,00.html"><IMG 
SRC="http://www.pixunlimited.co.uk/sys-images/Guardian/Pix/site_furniture/2000/04/13/gulogo.gif";
 ALT="Guardian Unlimited" HEIGHT="60" WIDTH="120" BORDER="0"></A></TD>
+       <TD WIDTH="468" ALIGN="RIGHT">
+ 
+
+<A 
HREF="http://ads.guardianunlimited.co.uk/click.ng/site=Guardian&amp;rand=2235220";>
+<IMG 
SRC="http://ads.guardianunlimited.co.uk/image.ng/site=Guardian&amp;rand=2235220";
 height=60 width=468 BORDER=0></A></TD>  
+</TR>
+</TABLE>
+</CENTER>
+<!-- Table for Guardian Stamp and Advert Banner -->
+
+<CENTER>
+<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" WIDTH="608"><TR VALIGN="TOP">
+       <TD WIDTH="100" VALIGN="TOP" HEIGHT=30><!--stamp here--><!-- Vignette 
V/5 Sun Aug 05 10:18:03 2001 -->
+<!--Guardian Stamp for furniture  table--><IMG 
SRC="http://www.pixunlimited.co.uk/guardian/site/Guardian_Observer_logo.gif"; 
WIDTH="80" HEIGHT="25" ALT="The Guardian" BORDER=0></TD>
+    <TD ALIGN="RIGHT" VALIGN="TOP" HEIGHT=30>
+                
+               <!-- Vignette V/5 Sat Aug 04 18:50:22 2001 -->
+
+<FORM NAME="network" METHOD="POST" 
ACTION="/redirect/1,1437,,00.html"><NOBR><FONT FACE="Geneva,Arial,sans-serif" 
SIZE="2"><B>Go to:</B>&nbsp;</FONT><SELECT NAME="Url" onChange="goUrl(this)">
+       <OPTION VALUE="/0,6961,,00.html">Guardian Unlimited home
+       <OPTION VALUE="/Politics/0,9215,,00.html">Politics
+       <OPTION VALUE="/Books/0,5917,,00.html">Books
+       <OPTION VALUE="/Education/0,5429,,00.html">EducationGuardian.co.uk
+       <OPTION VALUE="/clearing/0,10052,,00.html">Clearing
+       <OPTION VALUE="/Film/0,3968,,00.html">Film
+       <OPTION VALUE="/Sport/0,10065,,00.html">Sport
+       <OPTION VALUE="/Football/0,1327,,00.html">Football
+       <OPTION VALUE="/Jobs/0,5424,,00.html">Jobs
+       <OPTION VALUE="/Media/0,7502,,00.html">MediaGuardian.co.uk
+       <OPTION VALUE="/Society/0,7954,,00.html">SocietyGuardian.co.uk
+       <OPTION VALUE="/Money/0,6448,,00.html">Money
+       <OPTION VALUE="/Shopping/0,5800,,00.html">Shopping
+       <OPTION VALUE="/Travel/0,7448,,00.html">Travel
+       <OPTION VALUE="/Observer/0,6903,,00.html">The Observer
+       <OPTION VALUE="/Work/0,1735,,00.html">Work
+       <OPTION VALUE="/Archive/0,4271,,00.html">Search the archive
+       <OPTION VALUE=" ">----------------------
+       <OPTION VALUE="/0,6961,,00.html">News
+       <OPTION VALUE="/audio/0,8137,,00.html">Audio
+       <OPTION VALUE="/internetnews/0,7368,,00.html">Net news
+       <OPTION VALUE="/Documentaries/0,2479,,00.html">Special reports
+       <OPTION VALUE="/guardian/0,2844,,00.html">The Guardian
+       <OPTION VALUE="/uklatest/0,7721,,00.html">UK latest
+       <OPTION VALUE="/weblog/0,6798,,00.html">The weblog
+       <OPTION VALUE="/newslist/0,9750,,00.html">The newslist  
+       <OPTION VALUE="/thewrap/1,6280,,00.html">The wrap
+       <OPTION VALUE="/worldlatest/0,7722,,00.html">World latest
+       <OPTION VALUE="/artslatest/0,10079,,00.html">Arts latest
+       <OPTION VALUE=" ">----------------------
+       <OPTION VALUE="/crossword/0,4406,,00.html">Crossword
+       <OPTION VALUE="/distribution/0,5391,,00.html">Content distribution
+       <OPTION VALUE="/eventsandoffers/0,5993,,00.html">Events / offers
+       <OPTION VALUE="/gu_contacts/0,5816,180767,00.html">Help / contacts
+       <OPTION VALUE="/information/0,5816,,00.html">Information
+       <OPTION VALUE="/Lifeonline/0,6488,,00.html">Life online
+       <OPTION VALUE="/notesandqueries/0,5753,,00.html">Notes & Queries
+       <OPTION VALUE="/styleguide/0,5817,,00.html">Style guide
+       <OPTION VALUE="/eventsandoffers/travel2/0,6589,,00.html">Travel offers
+       <OPTION VALUE="/TV/0,4658,,00.html">TV listings
+       <OPTION VALUE="/Weather/0,4469,,00.html">Weather
+       <OPTION VALUE="/index/webguides/0,3109,,00.html">Web guides
+       <OPTION VALUE=" ">----------------------
+       <OPTION VALUE="/GWeekly/front/0,3936,,00.html">Guardian Weekly
+       <OPTION VALUE="/Money_Observer/0,5488,,00.html">Money Observer
+</SELECT>&nbsp;<INPUT TYPE="submit" VALUE="Go" 
onClick="goUrl(this.form.Url);return false;"></NOBR></FORM></TD>
+</TR>
+</TABLE>
+</CENTER>
+
+
+
+
+
+
+
+<CENTER>
+<TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=608>
+
+<TR>
+       <TD WIDTH=204>&nbsp;</TD>
+       <TD WIDTH=220 align="right" HEIGHT=22 valign=bottom><A 
HREF="/0,6961,,00.html"><IMG 
SRC="http://www.pixunlimited.co.uk/network/site/headers/guardian_unlim.gif"; 
WIDTH="132" HEIGHT="17" ALT="Guardian Unlimited" BORDER=0></TD> 
+       <TD valign=bottom width=184 align="center" HEIGHT=22 valign=bottom><A 
HREF="/Archive/0,4271,,00.html"><IMG 
SRC="http://www.pixunlimited.co.uk/network/site/archive/archive_crumb.gif"; 
WIDTH="120" HEIGHT="22" ALT="Archive" BORDER=0></A></TD>
+</TR>
+<TR>
+<TD width="608" height="22" COLSPAN="3">&nbsp;</TD>
+</TR>
+<TR>
+       <TD WIDTH="608" COLSPAN="3"><!-- Vignette V/5 Sun Aug 05 13:27:36 2001 
-->
+<!-- start Generic Textual Localnav -->
+
+                       
+
+       <STYLE>
+       <!--
+       A.GULOCALNAV0 { font-family: Arial,sans-serif; font-weight: bold; 
text-decoration: none; color: #999999; font-size: 14px; }
+       
+       A.GULOCALHOV0 { font-family: Arial,sans-serif; font-weight: bold; 
text-decoration: none; color: #000000; font-size: 14px; }     
+       
+       
+       
+       
+       A.GUHOMELINK { font-family: Arial,sans-serif; font-weight: bold; 
text-decoration: none; color: #000000; font-size: 14px; } 
+       
+       
+       // -->
+       </STYLE>
+
+
+       
+                
+       <SCRIPT LANGUAGE="JavaScript">
+       <!-- 
+       
+       /* Localnav: 2727. Subnavs:  */
+       
+               
+       var _Lwhat = 0;
+       var _Lthing;
+       var _Ldivobj = document.layers['gudropdown'];
+       var _Lcrnobj = document.layers['gucorner'];
+          var _Lready = false;
+
+       function rolloff() {
+               if (_Lready) {
+                        
+                       if (_Lwhat != 0) {
+                               _Lwhat.document.open();
+                               _Lwhat.document.write(_Lthing);
+                               _Lwhat.document.close();
+                               _Lwhat = 0;
+                       }
+                        }
+               return true;
+       }
+
+                
+       function roll(what, href, linktext) {
+               if (_Lready) {
+               var text =  '<NOBR><A HREF="' + href + '" CLASS="GULOCALHOV0">'
+                                               + linktext + '</A></NOBR>';
+                                               
+                       rolloff();
+       
+                       _Lthing =       '<NOBR><A HREF="' + href + '" 
CLASS="GULOCALNAV0">'
+                                               + linktext + '</A></NOBR>';
+                                               
+                       _Lwhat = what;
+                       
+               what.document.open();
+               what.document.write(text);
+               what.document.close();
+               }
+       
+               return true;
+       }
+       
+       function ddroll(what, href, linktext, colour) {
+               if (_Lready) {
+               var text =  '<NOBR>&nbsp;<A HREF="' + href + '" 
CLASS="GUDROPDOWN">';
+                       
+                       text += (colour == '' ? linktext : '<FONT COLOR="' + 
colour + '">' + linktext + '</FONT>'); 
+                       text += '</A>&nbsp;</NOBR>';
+       
+               what.document.open();
+               what.document.write(text);
+               what.document.close();
+               }
+               
+               return true;
+       }
+                  _Lready = true;
+
+       // -->
+       </SCRIPT>
+                
+       
+       <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="0"><TR><TD 
ALIGN="top"><ILAYER><LAYER onMouseOver="return rolloff()"><A 
HREF="http://www.guardian.co.uk"; CLASS="GUHOMELINK"><NOBR>Network 
home</NOBR></A></LAYER></ILAYER></TD><TD></TD>
+<TD><IMG SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" 
HEIGHT="8"></TD><TD WIDTH="1" BGCOLOR="#999999"><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="1" HEIGHT="1"></TD><TD><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" HEIGHT="10"></TD><TD 
ALIGN="top"><ILAYER><LAYER onMouseOver="return 
roll(this,'http://www.guardian.co.uk/uk_news','UK news')" onMouseOut="return 
rolloff()"><A HREF="http://www.guardian.co.uk/uk_news"; 
CLASS="GULOCALNAV0"><NOBR>UK news</NOBR></A></LAYER></ILAYER></TD><TD></TD>
+<TD><IMG SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" 
HEIGHT="8"></TD><TD WIDTH="1" BGCOLOR="#999999"><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="1" HEIGHT="1"></TD><TD><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" HEIGHT="10"></TD><TD 
ALIGN="top"><ILAYER><LAYER onMouseOver="return 
roll(this,'http://www.guardian.co.uk/worldlatest','World latest')" 
onMouseOut="return rolloff()"><A HREF="http://www.guardian.co.uk/worldlatest"; 
CLASS="GULOCALNAV0"><NOBR>World latest</NOBR></A></LAYER></ILAYER></TD><TD></TD>
+<TD><IMG SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" 
HEIGHT="8"></TD><TD WIDTH="1" BGCOLOR="#999999"><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="1" HEIGHT="1"></TD><TD><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" HEIGHT="10"></TD><TD 
ALIGN="top"><ILAYER><LAYER onMouseOver="return 
roll(this,'http://www.guardian.co.uk/books','Books')" onMouseOut="return 
rolloff()"><A HREF="http://www.guardian.co.uk/books"; 
CLASS="GULOCALNAV0"><NOBR>Books</NOBR></A></LAYER></ILAYER></TD><TD></TD>
+<TD><IMG SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" 
HEIGHT="8"></TD><TD WIDTH="1" BGCOLOR="#999999"><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="1" HEIGHT="1"></TD><TD><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" HEIGHT="10"></TD><TD 
ALIGN="top"><ILAYER><LAYER onMouseOver="return 
roll(this,'http://www.guardian.co.uk/money','Money')" onMouseOut="return 
rolloff()"><A HREF="http://www.guardian.co.uk/money"; 
CLASS="GULOCALNAV0"><NOBR>Money</NOBR></A></LAYER></ILAYER></TD><TD></TD>
+<TD><IMG SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" 
HEIGHT="8"></TD><TD WIDTH="1" BGCOLOR="#999999"><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="1" HEIGHT="1"></TD><TD><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" HEIGHT="10"></TD><TD 
ALIGN="top"><ILAYER><LAYER onMouseOver="return 
roll(this,'http://www.guardian.co.uk/film','Film')" onMouseOut="return 
rolloff()"><A HREF="http://www.guardian.co.uk/film"; 
CLASS="GULOCALNAV0"><NOBR>Film</NOBR></A></LAYER></ILAYER></TD><TD></TD>
+<TD><IMG SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" 
HEIGHT="8"></TD><TD WIDTH="1" BGCOLOR="#999999"><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="1" HEIGHT="1"></TD><TD><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" HEIGHT="10"></TD><TD 
ALIGN="top"><ILAYER><LAYER onMouseOver="return 
roll(this,'http://www.guardian.co.uk/society','Society')" onMouseOut="return 
rolloff()"><A HREF="http://www.guardian.co.uk/society"; 
CLASS="GULOCALNAV0"><NOBR>Society</NOBR></A></LAYER></ILAYER></TD><TD></TD>
+<TD><IMG SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" 
HEIGHT="8"></TD><TD WIDTH="1" BGCOLOR="#999999"><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="1" HEIGHT="1"></TD><TD><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" HEIGHT="10"></TD><TD 
ALIGN="top"><ILAYER><LAYER onMouseOver="return 
roll(this,'http://www.guardian.co.uk/Observer','The Observer')" 
onMouseOut="return rolloff()"><A HREF="http://www.guardian.co.uk/Observer"; 
CLASS="GULOCALNAV0"><NOBR>The Observer</NOBR></A></LAYER></ILAYER></TD><TD></TD>
+</TR><TR><TD COLSPAN="39" HEIGHT="1" BGCOLOR="#999999"><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="1" 
HEIGHT="1"></TD></TR><TR><TD ALIGN="top"><ILAYER><LAYER onMouseOver="return 
roll(this,'http://www.guardian.co.uk/politics','Politics')" onMouseOut="return 
rolloff()"><A HREF="http://www.guardian.co.uk/politics"; 
CLASS="GULOCALNAV0"><NOBR>Politics</NOBR></A></LAYER></ILAYER></TD><TD></TD>
+<TD><IMG SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" 
HEIGHT="8"></TD><TD WIDTH="1" BGCOLOR="#999999"><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="1" HEIGHT="1"></TD><TD><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" HEIGHT="10"></TD><TD 
ALIGN="top"><ILAYER><LAYER onMouseOver="return 
roll(this,'http://www.guardian.co.uk/education','Education')" 
onMouseOut="return rolloff()"><A HREF="http://www.guardian.co.uk/education"; 
CLASS="GULOCALNAV0"><NOBR>Education</NOBR></A></LAYER></ILAYER></TD><TD></TD>
+<TD><IMG SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" 
HEIGHT="8"></TD><TD WIDTH="1" BGCOLOR="#999999"><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="1" HEIGHT="1"></TD><TD><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" HEIGHT="10"></TD><TD 
ALIGN="top"><ILAYER><LAYER onMouseOver="return 
roll(this,'http://www.guardian.co.uk/shopping','Shopping')" onMouseOut="return 
rolloff()"><A HREF="http://www.guardian.co.uk/shopping"; 
CLASS="GULOCALNAV0"><NOBR>Shopping</NOBR></A></LAYER></ILAYER></TD><TD></TD>
+<TD><IMG SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" 
HEIGHT="8"></TD><TD WIDTH="1" BGCOLOR="#999999"><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="1" HEIGHT="1"></TD><TD><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" HEIGHT="10"></TD><TD 
ALIGN="top"><ILAYER><LAYER onMouseOver="return 
roll(this,'http://www.guardian.co.uk/work','Work')" onMouseOut="return 
rolloff()"><A HREF="http://www.guardian.co.uk/work"; 
CLASS="GULOCALNAV0"><NOBR>Work</NOBR></A></LAYER></ILAYER></TD><TD></TD>
+<TD><IMG SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" 
HEIGHT="8"></TD><TD WIDTH="1" BGCOLOR="#999999"><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="1" HEIGHT="1"></TD><TD><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" HEIGHT="10"></TD><TD 
ALIGN="top"><ILAYER><LAYER onMouseOver="return 
roll(this,'http://www.guardian.co.uk/football','Football')" onMouseOut="return 
rolloff()"><A HREF="http://www.guardian.co.uk/football"; 
CLASS="GULOCALNAV0"><NOBR>Football</NOBR></A></LAYER></ILAYER></TD><TD></TD>
+<TD><IMG SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" 
HEIGHT="8"></TD><TD WIDTH="1" BGCOLOR="#999999"><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="1" HEIGHT="1"></TD><TD><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" HEIGHT="10"></TD><TD 
ALIGN="top"><ILAYER><LAYER onMouseOver="return 
roll(this,'http://www.guardian.co.uk/jobs','Jobs')" onMouseOut="return 
rolloff()"><A HREF="http://www.guardian.co.uk/jobs"; 
CLASS="GULOCALNAV0"><NOBR>Jobs</NOBR></A></LAYER></ILAYER></TD><TD></TD>
+<TD><IMG SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" 
HEIGHT="8"></TD><TD WIDTH="1" BGCOLOR="#999999"><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="1" HEIGHT="1"></TD><TD><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" HEIGHT="10"></TD><TD 
ALIGN="top"><ILAYER><LAYER onMouseOver="return 
roll(this,'http://www.guardian.co.uk/media','Media')" onMouseOut="return 
rolloff()"><A HREF="http://www.guardian.co.uk/media"; 
CLASS="GULOCALNAV0"><NOBR>Media</NOBR></A></LAYER></ILAYER></TD><TD></TD>
+<TD><IMG SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" 
HEIGHT="8"></TD><TD WIDTH="1" BGCOLOR="#999999"><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="1" HEIGHT="1"></TD><TD><IMG 
SRC="http://www.pixunlimited.co.uk/sp.gif"; WIDTH="4" HEIGHT="10"></TD><TD 
ALIGN="top"><ILAYER><LAYER onMouseOver="return 
roll(this,'http://www.guardian.co.uk/Archive','Search')" onMouseOut="return 
rolloff()"><A HREF="http://www.guardian.co.uk/Archive"; 
CLASS="GULOCALNAV0"><NOBR>Search</NOBR></A></LAYER></ILAYER></TD><TD></TD>
+</TR></TABLE>
+<!-- end Generic Textual Localnav w--></TD>
+</TR>
+
+</TABLE>
+</CENTER>
+
+
+<CENTER>
+<TABLE WIDTH="544" BORDER="0" CELLPADDING="0" CELLSPACING="0">
+       <TR>
+               <TD WIDTH=32 HEIGHT=25><IMG 
SRC="http://www.pixunlimited.co.uk/global/grid/vspacer32.gif"; WIDTH=32 
HEIGHT=1></TD>
+               <TD VALIGN=TOP WIDTH=140 HEIGHT=25>&nbsp;</TD> 
+               <TD VALIGN=TOP WIDTH=372 HEIGHT=25>&nbsp;</TD>
+       </TR>
+
+       <TR>
+               <TD WIDTH=32 HEIGHT=1><IMG 
SRC="http://www.pixunlimited.co.uk/global/grid/vspacer32.gif"; WIDTH=32 
HEIGHT=1></TD>
+               <TD VALIGN=TOP WIDTH=140><img 
src="http://www.pixunlimited.co.uk/network/site/archive/archive_block.gif"; 
height="64" width="128" alt="Archive" BORDER=0><p><A 
HREF="/Archive/0,4271,,00.html"><img 
src="http://www.pixunlimited.co.uk/network/site/archive/search_again_1.gif"; 
height="20" width="128" alt="Archive" BORDER=0></A>&nbsp;</TD> 
+               <TD VALIGN=TOP WIDTH=372>
+            <FONT FACE="Arial,Helvetica,sans-serif" SIZE=4><B>Earth Lease 
steps up BT campaign</B></FONT>
+       
+               <FONT FACE="Arial,Helvetica,sans-serif" SIZE=3><p></FONT>
+        
+               <FONT FACE="Geneva,Arial,sans-serif" SIZE=2><B>Richard 
Wray</B></FONT><BR>
+        
+               <FONT FACE="Geneva,Arial,sans-serif" 
SIZE=2><B>Guardian</B></FONT><P>
+        <FONT FACE="Geneva,Arial,sans-serif" SIZE=2><B>Friday August 3, 
2001</B></FONT><P><P>
+       <FONT FACE="Geneva,Arial,sans-serif" SIZE=2>Pressure was mounting on 
British Telecom last night to reopen negotiations with Earth Lease after the 
investment consortium met telecoms regulator Oftel to outline its plan to buy 
BT's network of local phone lines. <P>Earth Lease is also understood to have 
called for a meeting with government officials within the next 10 days to 
explain how its sale and leaseback plan could be used to speed up the 
introduction of broadband services.  <P>The consortium, headed by financiers 
Babcock &amp; Brown, is attempting to build credibility with officials as a way 
of forcing BT to reconsider its initial dismissal of an &#163;8bn bid for the 
country's 28m local copper lines.  <P>It has already received indications of 
support from some of BT's largest customers who use the "local loop" to provide 
services such as video-on-demand.  <P>Earth Lease is expected to call a further 
meeting with Oftel later this month. However, the consortium has ruled out a di
 rect appeal to shareholders, believing that for any bid to work it must have 
the cooperation of BT's management and engineers.  <P>To bring this about, 
Earth Lease is willing to discuss the conditions that BT would need to place on 
any deal handing over control of the local network. Such conditions would 
include the ability of BT engineers to enter prem  ises in order to upgrade 
equipment.  <P>The Earth Lease bid comes at a time when BT is lobbying Oftel to 
end the controls which have capped the price it can levy in the UK market since 
privatisation in the 1980s. The local network plays a crucial role in the 
regulator's review.  <P>Spinning off BT's local network would make the 
regulator's job easier, as it would bring about the effective split of BT's 
wholesale operation from its retail arm, which could then be treated just as 
any other telecom provider.  <P>BT has been the subject of intense criticism 
from rival operators over the past year for its handling of the introduction of 
 competition into the local loop.  <P>Yesterday the European commission stepped 
up its drive for competition in the local loop - a process that was supposed to 
have started throughout the region at the beginning of last month.  <P>The 
commission is asking new entrants to the telecoms market to provide any 
information about incumbent operators who limit access to local copper networks 
as it tries to revitalise competition.  <P>The commission intends to report on 
the state of the industry by the end of the year and will take action against 
any operators it believes are guilty of anti-competitive behaviour.  
<P>Analysts said that it appears to be willing to take a more rigorous approach 
to telecoms competition. </FONT>
+</TD>
+       </TR>
+
+       <TR>
+               <TD WIDTH=32 HEIGHT=80>&nbsp;</TD>
+               <TD VALIGN=TOP WIDTH=140 HEIGHT=80>&nbsp;</TD> 
+               <TD VALIGN=TOP WIDTH=372 HEIGHT=80 VALIGN=MIDDLE>&nbsp;<P><A 
HREF="#top"><IMG 
SRC="http://www.pixunlimited.co.uk/football/site/Triangle_up.gif"; WIDTH=12 
HEIGHT=11 ALT="UP" BORDER="0"></A></TD>
+       </TR>
+       
+</TABLE>
+</CENTER>
+
+<CENTER>
+<TABLE BORDER=0 width=544 CELLPADDING="0" CELLSPACING="0">
+       
+       <TR>
+               <TD WIDTH=32 HEIGHT=1><A 
HREF="http://www.guardianunlimited.co.uk/credits.html";><IMG 
SRC="http://www.pixunlimited.co.uk/global/grid/spacer32.gif"; WIDTH=32 HEIGHT=1 
BORDER=0></A></TD>
+               <TD width=512 colspan=4 valign=TOP><CENTER>
+<FONT FACE="Geneva,Arial,sans-serif" SIZE=1>Guardian Unlimited &#169 Guardian 
Newspapers Limited 2001</FONT>
+</CENTER></TD>
+     </TR>
+</TABLE>
+</CENTER>
+
+
+</BODY>
+</HTML>
\ No newline at end of file

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
GATE-cvs mailing list
GATE-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gate-cvs

Reply via email to