package com.github.jochenw.afw.core.io;

import static org.junit.Assert.*;

import java.util.HashSet;
import java.util.Set;

import org.junit.Test;

/**
 * Test case for the {@link ClassLoaderResourceRepository}.
 */
public class ClassLoaderResourceRepositoryTest {
	/**
	 * Test case for {@link ClassLoaderResourceRepository#list(java.util.function.Consumer)}.
	 */
	@Test
	public void testList() {
		final Set<String> uris = new HashSet<>();
		final ClassLoaderResourceRepository clrr = new ClassLoaderResourceRepository();
		clrr.list((r) -> uris.add(r.getUri()));
		assertTrue(uris.contains("javax/servlet/Filter.class"));  // An entry from Maven's "compile" scope.
		assertTrue(uris.contains("org/junit/Test.class"));       // An entry from Maven's "test" scope.
		assertTrue(uris.contains("com/github/jochenw/afw/core/plugins/plugin-list.xsd")); // An entry from the "target/classes" folder.
		assertTrue(uris.contains("com/github/jochenw/afw/core/io/ClassLoaderResourceRepositoryTest.class")); // An entry from the "target/test-classes" folder.
		assertFalse(uris.contains("com/github/jochenw/afw/core/io/ClassLoaderResourceRepositoryTest.java"));
	}
}

@@ -151,16 +151,68 @@
 est;%0D%0A%0D%0A
+import com.github.jochenw.afw.core.util.Strings;%0D%0A%0D%0A
 /**%0D%0A * 
@@ -841,32 +841,56 @@
 .%0D%0A%09%09assertTrue(
+Strings.toString(uris), 
 uris.contains(%22c

Test fix #3 for Jenkins