expectConfigurationRequests( 7 );
archivaConfigurationControl.replay();
// Prepare Test.
action.prepare();
ProxyConnector connector = action.getConnector();
populateProxyConnector( connector );
// Perform Test w/no values.
preRequest( action );
String status = action.addProperty();
assertEquals( Action.INPUT, status );
// Should have returned an error, with no property pattern added.
assertHasErrors( action );
assertEquals( 0, connector.getProperties().size() );
// Try again, but now with a property key/value to add.
action.setPropertyKey( "eat-a" );
action.setPropertyValue( "gramov-a-bits" );
preRequest( action );
status = action.addProperty();
assertEquals( Action.INPUT, status );
// Should have no error, and 1 property added.
assertNoErrors( action );
assertEquals( 1, connector.getProperties().size() );
}