### Question:
PageCommand extends AbstractCommand { public Permission requiredPermission() { return m_permission; } private  PageCommand( final ContextEnum currentContext, final Page target, final String action ); private  PageCommand( final String requestContext,
                         final String urlPattern,
                         final String contentTemplate,
                         final Page target,
                         final String action ); Command targetedCommand( final Object target ); String getName(); Permission requiredPermission(); static final Command ATTACH; static final Command COMMENT; static final Command CONFLICT; static final Command DELETE; static final Command DIFF; static final Command EDIT; static final Command INFO; static final Command PREVIEW; static final Command RENAME; static final Command RSS; static final Command UPLOAD; static final Command VIEW; static final Command NONE; static final Command OTHER; }### Answer:
@Test public void testStaticCommand() { Command a = PageCommand.VIEW; Assertions.assertEquals( "view", a.getRequestContext() ); Assertions.assertEquals( "Wiki.jsp", a.getJSP() ); Assertions.assertEquals( "%uWiki.jsp?page=%n", a.getURLPattern() ); Assertions.assertEquals( "PageContent.jsp", a.getContentTemplate() ); Assertions.assertNull( a.getTarget()); Assertions.assertNull( a.requiredPermission() ); Assertions.assertEquals( a, PageCommand.VIEW ); a = PageCommand.EDIT; Assertions.assertEquals( "edit", a.getRequestContext() ); Assertions.assertEquals( "Edit.jsp", a.getJSP() ); Assertions.assertEquals( "%uEdit.jsp?page=%n", a.getURLPattern() ); Assertions.assertEquals( "EditContent.jsp", a.getContentTemplate() ); Assertions.assertNull( a.getTarget()); Assertions.assertNull( a.requiredPermission() ); Assertions.assertEquals( a, PageCommand.EDIT ); a = PageCommand.PREVIEW; Assertions.assertEquals( "preview", a.getRequestContext() ); Assertions.assertEquals( "Preview.jsp", a.getJSP() ); Assertions.assertEquals( "%uPreview.jsp?page=%n", a.getURLPattern() ); Assertions.assertEquals( "PreviewContent.jsp", a.getContentTemplate() ); Assertions.assertNull( a.getTarget()); Assertions.assertNull( a.requiredPermission() ); Assertions.assertEquals( a, PageCommand.PREVIEW ); }