X-Git-Url: https://git.argeo.org/?a=blobdiff_plain;f=osgi%2Fruntime%2Forg.argeo.osgi.boot%2Fsrc%2Ftest%2Fjava%2Forg%2Fargeo%2Fslc%2Fosgiboot%2FOsgiBootNoRuntimeTest.java;fp=osgi%2Fruntime%2Forg.argeo.osgi.boot%2Fsrc%2Ftest%2Fjava%2Forg%2Fargeo%2Fslc%2Fosgiboot%2FOsgiBootNoRuntimeTest.java;h=0000000000000000000000000000000000000000;hb=3f6778125ace0c2cf816a8cf532ef8210f24394e;hp=77f74d346c691f24a27d06bbea679759c7d9e370;hpb=9047fe4c52b416bf5168838565ab2ded119a80b7;p=lgpl%2Fargeo-commons.git diff --git a/osgi/runtime/org.argeo.osgi.boot/src/test/java/org/argeo/slc/osgiboot/OsgiBootNoRuntimeTest.java b/osgi/runtime/org.argeo.osgi.boot/src/test/java/org/argeo/slc/osgiboot/OsgiBootNoRuntimeTest.java deleted file mode 100644 index 77f74d346..000000000 --- a/osgi/runtime/org.argeo.osgi.boot/src/test/java/org/argeo/slc/osgiboot/OsgiBootNoRuntimeTest.java +++ /dev/null @@ -1,57 +0,0 @@ -/* - * Copyright (C) 2010 Mathieu Baudier - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package org.argeo.slc.osgiboot; - -import java.io.File; -import java.util.List; - -import junit.framework.TestCase; - -import org.argeo.osgi.boot.OsgiBoot; - -public class OsgiBootNoRuntimeTest extends TestCase { - public final static String BUNDLES = "src/test/bundles/some;in=*;ex=excluded," - + "src/test/bundles/others;in=**/org.argeo.*"; - - public void testLocations() { - String baseUrl = "file:"; - String locations = "/mydir/myfile" + File.pathSeparator - + "/myotherdir/myotherfile"; - - OsgiBoot osgiBoot = new OsgiBoot(null); - List urls = osgiBoot.getLocationsUrls(baseUrl, locations); - assertEquals(2, urls.size()); - assertEquals("file:/mydir/myfile", urls.get(0)); - assertEquals("file:/myotherdir/myotherfile", urls.get(1)); - } - - public void testBundles() { - String baseUrl = "file:"; - String bundles = BUNDLES; - OsgiBoot osgiBoot = new OsgiBoot(null); - List urls = osgiBoot.getBundlesUrls(baseUrl, bundles); - for (int i = 0; i < urls.size(); i++) - System.out.println(urls.get(i)); - assertEquals(3, urls.size()); - - List jarUrls = osgiBoot.getBundlesUrls(baseUrl, - "src/test/bundles/jars;in=*.jar"); - for (int i = 0; i < jarUrls.size(); i++) - System.out.println(jarUrls.get(i)); - assertEquals(1, jarUrls.size()); - } -}