@ -17,8 +17,10 @@ package org.springframework.data.mongodb.repository.aot;
@@ -17,8 +17,10 @@ package org.springframework.data.mongodb.repository.aot;
import java.io.IOException ;
import java.lang.annotation.Annotation ;
import java.util.Collection ;
import java.util.List ;
import java.util.Set ;
import java.util.function.Consumer ;
import org.jspecify.annotations.Nullable ;
@ -28,6 +30,7 @@ import org.springframework.core.env.Environment;
@@ -28,6 +30,7 @@ import org.springframework.core.env.Environment;
import org.springframework.core.env.StandardEnvironment ;
import org.springframework.core.io.ClassPathResource ;
import org.springframework.core.test.tools.ClassFile ;
import org.springframework.data.aot.AotTypeConfiguration ;
import org.springframework.data.mongodb.core.mapping.Document ;
import org.springframework.data.mongodb.repository.support.MongoRepositoryFragmentsContributor ;
import org.springframework.data.mongodb.repository.support.SimpleMongoRepository ;
@ -77,6 +80,16 @@ public class TestMongoAotRepositoryContext implements AotRepositoryContext {
@@ -77,6 +80,16 @@ public class TestMongoAotRepositoryContext implements AotRepositoryContext {
return null ;
}
@Override
public void typeConfiguration ( Class < ? > type , Consumer < AotTypeConfiguration > configurationConsumer ) {
}
@Override
public Collection < AotTypeConfiguration > typeConfigurations ( ) {
return List . of ( ) ;
}
@Override
public String getBeanName ( ) {
return "dummyRepository" ;
@ -117,6 +130,11 @@ public class TestMongoAotRepositoryContext implements AotRepositoryContext {
@@ -117,6 +130,11 @@ public class TestMongoAotRepositoryContext implements AotRepositoryContext {
return Set . of ( ) ;
}
@Override
public Set < Class < ? > > getUserDomainTypes ( ) {
return Set . of ( ) ;
}
public List < ClassFile > getRequiredContextFiles ( ) {
return List . of ( classFileForType ( repositoryInformation . getRepositoryBaseClass ( ) ) ) ;
}