Code example for DatagramPacket

Methods: setData

0
        } catch(NullPointerException expected) {
        } 
    } 
 
    public void test_setData$B() { 
        dp = new DatagramPacket("Hello".getBytes(), 5);
        try { 
            dp.setData(null);
            fail("NullPointerException was not thrown.");
        } catch(NullPointerException expected) {
        } 
    } 
}