diff options
Diffstat (limited to 'bundles/org.eclipse.osgi.tests/src/org/eclipse/osgi/tests/bundles/URLHandlerTests.java')
-rw-r--r-- | bundles/org.eclipse.osgi.tests/src/org/eclipse/osgi/tests/bundles/URLHandlerTests.java | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/bundles/org.eclipse.osgi.tests/src/org/eclipse/osgi/tests/bundles/URLHandlerTests.java b/bundles/org.eclipse.osgi.tests/src/org/eclipse/osgi/tests/bundles/URLHandlerTests.java index 3751a22e0..d37277369 100644 --- a/bundles/org.eclipse.osgi.tests/src/org/eclipse/osgi/tests/bundles/URLHandlerTests.java +++ b/bundles/org.eclipse.osgi.tests/src/org/eclipse/osgi/tests/bundles/URLHandlerTests.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2015 IBM Corporation and others. + * Copyright (c) 2015, 2018 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -10,6 +10,8 @@ *******************************************************************************/ package org.eclipse.osgi.tests.bundles; +import java.awt.image.ImageProducer; +import java.io.IOException; import java.net.URL; import junit.framework.Test; import junit.framework.TestSuite; @@ -31,4 +33,10 @@ public class URLHandlerTests extends AbstractBundleTests { testURL.openConnection().connect(); } + public void testImageProducer() throws IOException { + URL testImage = getClass().getResource("debug.gif"); + Object content = testImage.getContent(); + assertTrue("Wrong content type: " + content.getClass().getName(), content instanceof ImageProducer); + } + } |