Package org.usb4java

Examples of org.usb4java.Context


     */
    @Test
    public void testInitDeinitWithContext()
    {
        assumeUsbTestsEnabled();
        final Context context = new Context();
        assertEquals(LibUsb.SUCCESS, LibUsb.init(context));
        LibUsb.exit(context);

        try
        {
View Full Code Here


     */
    @Test(expected = IllegalStateException.class)
    public void testExitWithUninitializedContext()
    {
        assumeUsbTestsEnabled();
        final Context context = new Context();
        LibUsb.exit(context);
    }
View Full Code Here

     */
    @Test(expected = IllegalStateException.class)
    public void testSetDebugWithUninitializedContext()
    {
        assumeUsbTestsEnabled();
        final Context context = new Context();
        LibUsb.setDebug(context, 0);
    }
View Full Code Here

     */
    @Test(expected = IllegalStateException.class)
    public void testGetDeviceListWithUninitializedContext()
    {
        assumeUsbTestsEnabled();
        final Context context = new Context();
        LibUsb.getDeviceList(context, new DeviceList());
    }
View Full Code Here

     */
    @Test(expected = IllegalStateException.class)
    public void testOpenDeviceWithVidPid()
    {
        assumeUsbTestsEnabled();
        final Context context = new Context();
        LibUsb.openDeviceWithVidPid(context, (short) 0, (short) 0);
    }
View Full Code Here

     */
    @Test(expected = IllegalStateException.class)
    public void testTryLockEventsWithUninitializedContext()
    {
        assumeUsbTestsEnabled();
        final Context context = new Context();
        LibUsb.tryLockEvents(context);
    }
View Full Code Here

     */
    @Test(expected = IllegalStateException.class)
    public void testLockEventsWithUninitializedContext()
    {
        assumeUsbTestsEnabled();
        final Context context = new Context();
        LibUsb.lockEvents(context);
    }
View Full Code Here

     */
    @Test(expected = IllegalStateException.class)
    public void testUnlockEventsWithUninitializedContext()
    {
        assumeUsbTestsEnabled();
        final Context context = new Context();
        LibUsb.unlockEvents(context);
    }
View Full Code Here

     */
    @Test(expected = IllegalStateException.class)
    public void testEventHandlingOkWithUninitializedContext()
    {
        assumeUsbTestsEnabled();
        final Context context = new Context();
        LibUsb.eventHandlingOk(context);
    }
View Full Code Here

     */
    @Test(expected = IllegalStateException.class)
    public void testEventHandlerActiveWithUninitializedContext()
    {
        assumeUsbTestsEnabled();
        final Context context = new Context();
        LibUsb.eventHandlerActive(context);
    }
View Full Code Here

TOP

Related Classes of org.usb4java.Context

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.