Changeset 6926


Ignore:
Timestamp:
01/26/16 15:16:55 (8 years ago)
Author:
Menzo Windhouwer
Message:

M toolkit/src/test/java/eu/clarin/cmd/toolkit/TestCMDToolkit.java

  • print statement to make clearer which messages belong to a test
File:
1 edited

Legend:

Unmodified
Added
Removed
  • metadata/trunk/toolkit/src/test/java/eu/clarin/cmd/toolkit/TestCMDToolkit.java

    r6925 r6926  
    197197    @Test
    198198    public void testAdelheid() throws Exception {
     199        System.out.println("* BEGIN: Adelheid tests (valid)");
     200       
    199201        String profile = "/toolkit/Adelheid/profiles/clarin.eu:cr1:p_1311927752306.xml";
    200202        String record  = "/toolkit/Adelheid/records/Adelheid.cmdi";
    201203
    202204        // upgrade the profile from 1.1 to 1.2
     205        System.out.println("- upgrade profile from 1.1 to 1.2");
    203206        Document upgradedProfile = upgradeCMDSpec(profile);
    204207
     
    217220
    218221        // upgrade the record from 1.1 to 1.2
     222        System.out.println("- upgrade record from 1.1 to 1.2");
    219223        Document upgradedRecord = upgradeCMDRecord(record,upgradedProfile);
    220224
     
    229233       
    230234        // downgrade the 1.2 profile to 1.1
     235        System.out.println("- downgrade profile from 1.2 to 1.1");
    231236        Document oldProfile = downgradeCMDSpec(profile+" (upgraded)",new DOMSource(upgradedProfile));
    232237       
     
    239244        // so there should be no errors
    240245        assertEquals(0, countErrors(validateCMDoldSpec));       
     246
     247        System.out.println("*  END : Adelheid tests");
    241248    }
    242249
    243250    @Test
    244251    public void testAdelheid2() throws Exception {
     252        System.out.println("* BEGIN: Adelheid 2 tests (invalid)");
     253
    245254        String profile = "/toolkit/Adelheid/profiles/clarin.eu:cr1:p_1311927752306_1_2.xml";
    246255        String record  = "/toolkit/Adelheid/records/Adelheid_1_2-invalid.cmdi";
     
    275284        assertTrue(validOldProfile);
    276285        // so there should be no errors
    277         assertEquals(0, countErrors(validateCMDoldSpec));       
     286        assertEquals(0, countErrors(validateCMDoldSpec));   
     287       
     288        System.out.println("*  END : Adelheid 2 tests");
    278289    }
    279290
    280291    @Test
    281292    public void testSundhed() throws Exception {
     293        System.out.println("* BEGIN: Sundhed tests (valid)");
     294       
    282295        String profile = "/toolkit/TEI/profiles/clarin.eu:cr1:p_1380106710826.xml";
    283296        String record  = "/toolkit/TEI/records/sundhed_dsn.teiHeader.ref.xml";
     
    323336        // so there should be no errors
    324337        assertEquals(0, countErrors(validateCMDoldSpec));       
     338
     339        System.out.println("*  END : Sundhed tests");
    325340    }
    326341
    327342    @Test
    328343    public void testTEI() throws Exception {
     344        System.out.println("* BEGIN: TEI tests (valid)");
     345
    329346        String profile = "/toolkit/TEI/profiles/clarin.eu:cr1:p_1380106710826.xml";
    330347        String record  = "/toolkit/TEI/records/sundhed_dsn.teiHeader.ref.xml";
     
    339356        // the @ref attributes on the elements should stay as they are
    340357        assertTrue(xpath(upgradedRecord,"//*:author/*:name/@ref"));
     358
     359        System.out.println("*  END : TEI tests");
    341360    }
    342361
    343362    @Test
    344363    public void testSuccessor() throws Exception {
     364        System.out.println("* BEGIN: successor tests (valid+invalid)");
     365       
    345366        String validRecord  = "/toolkit/successor/profiles/successor-valid.xml";
    346367        String invalidRecord  = "/toolkit/successor/profiles/successor-invalid.xml";
     
    349370        assertTrue(validateCMDSpec(validRecord));
    350371        assertFalse(validateCMDSpec(invalidRecord));
     372       
     373        System.out.println("*  END : successor tests");
    351374    }
    352375
    353376    @Test
    354377    public void testOLAC() throws Exception {
     378        System.out.println("* BEGIN: OLAC tests (invalid)");
     379       
    355380        String profile = "/toolkit/OLAC/profiles/OLAC-DcmiTerms.xml";
    356381        String record  = "/toolkit/OLAC/records/org_rosettaproject-record.xml";
     
    391416        assertTrue(validOldProfile);
    392417        // so there should be no errors
    393         assertEquals(0, countErrors(validateCMDoldSpec));       
     418        assertEquals(0, countErrors(validateCMDoldSpec));
     419       
     420        System.out.println("*  END : OLAC tests");
    394421    }
    395422
    396423    @Test
    397424    public void testCMD() throws Exception {
     425        System.out.println("* BEGIN: CMD tests (invalid)");
     426       
    398427        String profile = "/toolkit/CMD/profiles/components-invalid.xml";
    399428
     
    403432        // assertions
    404433        assertFalse(validProfile);
     434
     435        System.out.println("*  END : CMD tests");
    405436    }
    406437
Note: See TracChangeset for help on using the changeset viewer.