//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test void whenContextCallsLoaderBlocksServicesFolderShouldLoadClassFromKernelClassloader() internal virtual void WhenContextCallsLoaderBlocksServicesFolderShouldLoadClassFromKernelClassloader() { Thread.CurrentThread.ContextClassLoader = new ServiceBlockClassLoader(_contextClassLoader); FooService fooService = Service.Load(typeof(FooService), "foo"); assertTrue(fooService is BarService); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test void whenContextClassLoaderOverridesServiceShouldLoadThatClass() internal virtual void WhenContextClassLoaderOverridesServiceShouldLoadThatClass() { Thread.CurrentThread.ContextClassLoader = new ServiceRedirectClassLoader(_contextClassLoader); FooService fooService = Service.Load(typeof(FooService), "foo"); assertTrue(fooService is BazService); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test void shouldLoadServiceInDefaultEnvironment() internal virtual void ShouldLoadServiceInDefaultEnvironment() { FooService fooService = Service.Load(typeof(FooService), "foo"); assertTrue(fooService is BarService); }