@Test
public void uiConfiguration()
throws Exception
{
UiConfiguration oldUi = archivaAdministration.getUiConfiguration();
assertNotNull( oldUi );
// assert default values
assertFalse( oldUi.isDisableEasterEggs() );
assertTrue( oldUi.isAppletFindEnabled() );
assertTrue( oldUi.isShowFindArtifacts() );
assertFalse( oldUi.isDisableRegistration() );
UiConfiguration ui = archivaAdministration.getUiConfiguration();
ui.setAppletFindEnabled( false );
ui.setShowFindArtifacts( false );
ui.setDisableEasterEggs( true );
ui.setDisableRegistration( true );
archivaAdministration.updateUiConfiguration( ui );
ui = archivaAdministration.getUiConfiguration();
assertTrue( ui.isDisableEasterEggs() );
assertFalse( ui.isAppletFindEnabled() );
assertFalse( ui.isShowFindArtifacts() );
assertTrue( ui.isDisableRegistration() );
archivaAdministration.updateUiConfiguration( oldUi );
}