mil.dod.th.ose.sdk/test/mil/dod/th/ose/sdk/those/TestProjectTransportLayerCapabilities.java
@Test
    public void testGetCapabilities()
    {
        // get the byte array of the capabilities xml
        final byte[] capByte = ProjectTransportLayerCapabilities.getCapabilities();

        // read the byte array to a string object, used as the string to test against
        String lineAccum = new String(capByte);

        // assert that each main tag contains the correct sub-tags and/or fields
        ProjectCapabilitiesUtils.assertTestPattern("<ns2:TransportLayerCapabilities",
                "</ns2:TransportLayerCapabilities>", "<primaryImage", lineAccum);
        ProjectCapabilitiesUtils.assertTestPattern("<ns2:TransportLayerCapabilities",
                "</ns2:TransportLayerCapabilities>", "<secondaryImages", lineAccum);
        ProjectCapabilitiesUtils.assertTestPattern("<ns2:TransportLayerCapabilities",
                "</ns2:TransportLayerCapabilities>", "productName", lineAccum);
        ProjectCapabilitiesUtils.assertTestPattern("<ns2:TransportLayerCapabilities",
                "</ns2:TransportLayerCapabilities>", "description", lineAccum);
        ProjectCapabilitiesUtils.assertTestPattern("<ns2:TransportLayerCapabilities",
                "</ns2:TransportLayerCapabilities>", "manufacturer", lineAccum);

        ProjectCapabilitiesUtils.assertElement(lineAccum, "ns2:linkLayerModalitiesSupported", "LineOfSight");
        ProjectCapabilitiesUtils.assertElement(lineAccum, "ns2:linkLayerModalitiesSupported", "SATCOM");
        ProjectCapabilitiesUtils.assertElement(lineAccum, "ns2:linkLayerModalitiesSupported", "Cellular");

        ProjectCapabilitiesUtils.assertTestPattern("<primaryImage", "/primaryImage>", "encoding", lineAccum);

        ProjectCapabilitiesUtils.assertTestPattern("<secondaryImages", "/secondaryImages>", "encoding", lineAccum);
        
        // assume most plug-ins are not connection oriented
        ProjectCapabilitiesUtils.assertElement(lineAccum, "ns2:connectionOriented", "false");
    }
/**
     * Tests that the {@link ProjectTransportLayerCapabilities#getCapabilities()} returns an object containing the
     * correct XML tags.
     */
Tests that the  ProjectTransportLayerCapabilities#getCapabilities() returns an object containing the
correct XML tags.
Tests that the ProjectTransportLayerCapabilities#getCapabilities () returns an object containing the correct XML tags .
@Test
    public void testGetCapabilities()
    {
        final byte[] capByte = ProjectTransportLayerCapabilities.getCapabilities();
        String lineAccum = new String(capByte);
        ProjectCapabilitiesUtils.assertTestPattern("<ns2:TransportLayerCapabilities",
                "</ns2:TransportLayerCapabilities>", "<primaryImage", lineAccum);
        ProjectCapabilitiesUtils.assertTestPattern("<ns2:TransportLayerCapabilities",
                "</ns2:TransportLayerCapabilities>", "<secondaryImages", lineAccum);
        ProjectCapabilitiesUtils.assertTestPattern("<ns2:TransportLayerCapabilities",
                "</ns2:TransportLayerCapabilities>", "productName", lineAccum);
        ProjectCapabilitiesUtils.assertTestPattern("<ns2:TransportLayerCapabilities",
                "</ns2:TransportLayerCapabilities>", "description", lineAccum);
        ProjectCapabilitiesUtils.assertTestPattern("<ns2:TransportLayerCapabilities",
                "</ns2:TransportLayerCapabilities>", "manufacturer", lineAccum);
        ProjectCapabilitiesUtils.assertElement(lineAccum, "ns2:linkLayerModalitiesSupported", "LineOfSight");
        ProjectCapabilitiesUtils.assertElement(lineAccum, "ns2:linkLayerModalitiesSupported", "SATCOM");
        ProjectCapabilitiesUtils.assertElement(lineAccum, "ns2:linkLayerModalitiesSupported", "Cellular");
        ProjectCapabilitiesUtils.assertTestPattern("<primaryImage", "/primaryImage>", "encoding", lineAccum);
        ProjectCapabilitiesUtils.assertTestPattern("<secondaryImages", "/secondaryImages>", "encoding", lineAccum);
        ProjectCapabilitiesUtils.assertElement(lineAccum, "ns2:connectionOriented", "false");
    }
@ Test public void testGetCapabilities ( ) { final byte [ ] capByte = ProjectTransportLayerCapabilities . getCapabilities ( ) ; String lineAccum = new String ( capByte ) ; ProjectCapabilitiesUtils . assertTestPattern ( "<ns2:TransportLayerCapabilities" , "</ns2:TransportLayerCapabilities>" , "<primaryImage" , lineAccum ) ; ProjectCapabilitiesUtils . assertTestPattern ( "<ns2:TransportLayerCapabilities" , "</ns2:TransportLayerCapabilities>" , "<secondaryImages" , lineAccum ) ; ProjectCapabilitiesUtils . assertTestPattern ( "<ns2:TransportLayerCapabilities" , "</ns2:TransportLayerCapabilities>" , "productName" , lineAccum ) ; ProjectCapabilitiesUtils . assertTestPattern ( "<ns2:TransportLayerCapabilities" , "</ns2:TransportLayerCapabilities>" , "description" , lineAccum ) ; ProjectCapabilitiesUtils . assertTestPattern ( "<ns2:TransportLayerCapabilities" , "</ns2:TransportLayerCapabilities>" , "manufacturer" , lineAccum ) ; ProjectCapabilitiesUtils . assertElement ( lineAccum , "ns2:linkLayerModalitiesSupported" , "LineOfSight" ) ; ProjectCapabilitiesUtils . assertElement ( lineAccum , "ns2:linkLayerModalitiesSupported" , "SATCOM" ) ; ProjectCapabilitiesUtils . assertElement ( lineAccum , "ns2:linkLayerModalitiesSupported" , "Cellular" ) ; ProjectCapabilitiesUtils . assertTestPattern ( "<primaryImage" , "/primaryImage>" , "encoding" , lineAccum ) ; ProjectCapabilitiesUtils . assertTestPattern ( "<secondaryImages" , "/secondaryImages>" , "encoding" , lineAccum ) ; ProjectCapabilitiesUtils . assertElement ( lineAccum , "ns2:connectionOriented" , "false" ) ; }
Tests that the {@link ProjectTransportLayerCapabilities#getCapabilities()} returns an object containing the
 correct XML tags.
Tests that the { @link ProjectTransportLayerCapabilities#getCapabilities () } returns an object containing the correct XML tags .
// get the byte array of the capabilities xml // read the byte array to a string object, used as the string to test against // assert that each main tag contains the correct sub-tags and/or fields // assume most plug-ins are not connection oriented