mirror of
https://github.com/google/nomulus
synced 2026-09-07 16:47:03 +00:00
Only show OT&E admin actions when not in production environment
------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=237061813
This commit is contained in:
@@ -60,6 +60,7 @@ registry.registrar.ConsoleTestUtil.renderConsoleMain = function(
|
||||
announcementsEmail: args.announcementsEmail || 'announcement@example.com',
|
||||
supportPhoneNumber: args.supportPhoneNumber || '+1 (888) 555 0123',
|
||||
technicalDocsUrl: args.technicalDocsUrl || 'http://example.com/techdocs',
|
||||
environment: args.environment || 'UNITTEST',
|
||||
});
|
||||
};
|
||||
|
||||
|
||||
@@ -27,6 +27,7 @@ import com.google.appengine.api.users.User;
|
||||
import com.google.appengine.api.users.UserServiceFactory;
|
||||
import com.google.common.collect.ImmutableSetMultimap;
|
||||
import com.google.common.net.MediaType;
|
||||
import google.registry.config.RegistryEnvironment;
|
||||
import google.registry.request.auth.AuthLevel;
|
||||
import google.registry.request.auth.AuthResult;
|
||||
import google.registry.request.auth.AuthenticatedRegistrarAccessor;
|
||||
@@ -78,6 +79,7 @@ public class ConsoleUiActionTest {
|
||||
action.paramClientId = Optional.empty();
|
||||
AuthResult authResult = AuthResult.create(AuthLevel.USER, UserAuthInfo.create(user, false));
|
||||
action.authResult = authResult;
|
||||
action.environment = RegistryEnvironment.UNITTEST;
|
||||
|
||||
action.registrarAccessor =
|
||||
AuthenticatedRegistrarAccessor.createForTesting(
|
||||
|
||||
BIN
Binary file not shown.
|
Before Width: | Height: | Size: 52 KiB After Width: | Height: | Size: 50 KiB |
BIN
Binary file not shown.
|
Before Width: | Height: | Size: 53 KiB After Width: | Height: | Size: 52 KiB |
BIN
Binary file not shown.
|
Before Width: | Height: | Size: 50 KiB After Width: | Height: | Size: 49 KiB |
Reference in New Issue
Block a user