### Question:
ArchivaVersion extends BaseContentItem implements Version { public static WithProjectBuilder withAsset( StorageAsset storageAsset ) { return new Builder( ).withAsset( storageAsset ); } private  ArchivaVersion( ); static WithProjectBuilder withAsset( StorageAsset storageAsset ); static WithAssetBuilder<WithProjectBuilder> withRepository( ManagedRepositoryContent repository ); @Override List<String> getVersionSegments( ); @Override String getId( ); @Override Project getProject( ); @Override Namespace getNamespace( ); @Override boolean equals( Object o ); @Override int hashCode( ); @Override String toString( );  }### Answer:
@Test void illegalVersion() { WithVersionBuilder builder = ArchivaVersion.withAsset( asset ).withProject( project ); assertThrows( IllegalArgumentException.class, ( ) -> builder.withVersion( null ) ); assertThrows( IllegalArgumentException.class, ( ) -> builder.withVersion( "" ) ); }