ManagedRepositoryConfiguration managedRepo = createManagedRepo( "legacy", "legacy-repo" );
archivaConfigControl.expectAndReturn( archivaConfig.getConfiguration(), config );
configControl.expectAndReturn( config.findManagedRepositoryById( "internal" ), managedRepo );
ManagedLegacyRepositoryContent repoContent = new ManagedLegacyRepositoryContent();
repoContent.setRepository( managedRepo );
repoContent.setFileTypes( fileTypes );
repoContent.setLegacyPathParser( parser );
repoFactoryControl.expectAndReturn( repositoryFactory.getManagedRepositoryContent( "internal" ), repoContent );
recordInManagedLegacyRepoContent( fileTypesControl, fileTypes, pathParserControl, parser );