@Test
public void failsSetInstanceOfProviderBinderWhenDoNotHaveProvidersManagePermission() throws Exception {

    try {
        setupSecurityManager();
        ProviderBinder providerBinder = mock(ProviderBinder.class);
        thrown.expect(SecurityException.class);
        ProviderBinder.setInstance(providerBinder);
    } finally {
        restoreSecurityManager();
    }
}