Package com.pugh.sockso.tests

Examples of com.pugh.sockso.tests.TestOptionSet


    @Override
    protected void setUp() {
        p = new StringProperties();
        p.set( Constants.WWW_USERS_REQUIRE_LOGIN, p.YES );
        res = new TestResponse();
        api = new Api( new ObjectCache(), Guice.createInjector(new SocksoModule(new TestOptionSet())) );
        api.setProperties( p );
        api.setResponse( res );
    }
View Full Code Here


    }

    public void testGetIpFromOptions() {

        final TestOptionSet options = new TestOptionSet();
        final StringProperties p = new StringProperties();
        final String ip = "123.123.123.123";
        final IpFinder f = new IpFinder( p, options );

        options.addHas( Options.OPT_IP, ip );

        assertEquals( ip, f.getIpFromOptions() );
       
    }
View Full Code Here

       
    }

    public void testGetIpFromOptionsNothingSpecified() {

        final TestOptionSet options = new TestOptionSet();
        final StringProperties p = new StringProperties();
        final String ip = "123.123.123.123";
        final IpFinder f = new IpFinder( p, options );

        assertNull( f.getIpFromOptions() );
View Full Code Here

    private Injector injector;
   
    @Override
    protected void setUp() {
        injector = Guice.createInjector( new SocksoModule(new TestOptionSet()) );
    }
View Full Code Here

TOP

Related Classes of com.pugh.sockso.tests.TestOptionSet

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.