Package com.volantis.testtools.io

Examples of com.volantis.testtools.io.ReplayInputStream


    public TestURLTestCase(String name) {
        super( name );
    }
   
    public void testURLConnection() throws Exception {
        InputStream dataIS = new ReplayInputStream(
                      new ByteArrayInputStream( "My Test Data".getBytes()) );
        TestURLRegistry.register( "replay", dataIS);
       
        URL url = new URL( "testurl:replay" );
        InputStream in = url.openStream();
View Full Code Here


                .append( "user-agent: My little browser.\n\n" )
                .append( "<html>\n<body>\n<p>Hello World</p>\n</body>\n</html>\n" );
       
        System.out.println( "length is " + response.length() );
       
        InputStream dataIS = new ReplayInputStream(
                      new ByteArrayInputStream( response.toString().getBytes()) );
        TestURLRegistry.register( "replay", dataIS);
       
        URL url = new URL( "testurl:replay" );
        URLConnection conn = url.openConnection();
View Full Code Here

TOP

Related Classes of com.volantis.testtools.io.ReplayInputStream

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.