use of com.newrelic.weave.weavepackage.CachedWeavePackage in project newrelic-java-agent by newrelic.
the class TestCachedWeavePackage method testCachedWeavePackage.
/**
* Test to make sure internal WeavePackage caching is working.
*/
@Test
public void testCachedWeavePackage() {
WeavePackage internalPackage = manager.getWeavePackage("com.newrelic.instrumentation.servlet-2.4");
Assert.assertNotNull(internalPackage);
Assert.assertTrue("Class type is " + internalPackage.getClass().getName(), internalPackage instanceof CachedWeavePackage);
WeavePackage externalPackage = manager.getWeavePackage("Weave Test");
Assert.assertNotNull(externalPackage);
Assert.assertFalse(externalPackage instanceof CachedWeavePackage);
}
Aggregations