Message msg = GstMessageAPI.GSTMESSAGE_API.gst_message_new_duration(fakesink, Format.TIME, DURATION);
assertTrue("gst_message_new_duration did not return an instance of DurationMessage", msg instanceof DurationMessage);
}
@Test public void DurationMessage_getDuration() {
Element fakesink = ElementFactory.make("fakesink", "sink");
DurationMessage msg = (DurationMessage)GstMessageAPI.GSTMESSAGE_API.gst_message_new_duration(fakesink, Format.TIME, DURATION);
assertEquals("Wrong duration in message", DURATION, msg.getDuration());
}