Package org.jacorb.test.orb

Source Code of org.jacorb.test.orb.CDROutputStreamTest

/*
*        JacORB - a free Java ORB
*
*   Copyright (C) 1999-2004 Gerald Brose
*
*   This library is free software; you can redistribute it and/or
*   modify it under the terms of the GNU Library General Public
*   License as published by the Free Software Foundation; either
*   version 2 of the License, or (at your option) any later version.
*
*   This library is distributed in the hope that it will be useful,
*   but WITHOUT ANY WARRANTY; without even the implied warranty of
*   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
*   Library General Public License for more details.
*
*   You should have received a copy of the GNU Library General Public
*   License along with this library; if not, write to the Free
*   Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*
*/

package org.jacorb.test.orb;

import org.jacorb.orb.CDROutputStream;
import org.omg.CORBA.ORB;

import junit.framework.Test;
import junit.framework.TestCase;
import junit.framework.TestSuite;

public class CDROutputStreamTest extends TestCase
{
    private CDROutputStream objectUnderTest;
    private ORB orb;
   
    protected void setUp() throws Exception
    {
        super.setUp();
       
        orb = ORB.init(new String[0], null);
        objectUnderTest = new CDROutputStream(orb);
    }
   
    public void testIncreaseSize()
    {
        byte[] buffer = new byte[4];
        objectUnderTest.setBuffer(buffer);
               
        objectUnderTest.increaseSize(8);
       
        assertTrue(objectUnderTest.size() >= 8);
    }
   
    public static Test suite()
    {
        return new TestSuite(CDROutputStreamTest.class);
    }
}
TOP

Related Classes of org.jacorb.test.orb.CDROutputStreamTest

TOP
Copyright © 2018 www.massapi.com. 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.