File tree Expand file tree Collapse file tree
src/test/java/com/google/adk/models/springai/ollama Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -668,16 +668,19 @@ The library includes comprehensive integration tests for different providers:
668668### Running Integration Tests
669669
670670``` bash
671- # Opt in to integration tests (gates the Gemini and Ollama tests)
671+ # Opt in to GeminiApiIntegrationTest
672672export ADK_RUN_INTEGRATION_TESTS=true
673673# Set Gemini model name for integration tests
674- export GEMINi_MODEL =gemini-3.8-flash
674+ export GEMINI_MODEL =gemini-3.8-flash
675675
676676# Set required environment variables
677677export OPENAI_API_KEY=your_key
678678export GOOGLE_CLOUD_PROJECT=your_project_id
679679export ANTHROPIC_API_KEY=your_key
680680
681+ # Opt in to LocalModelIntegrationTest, which runs Ollama in Docker
682+ export ADK_RUN_LOCAL_MODEL_TESTS=true
683+
681684# Run specific integration test
682685mvn test -Dtest=OpenAiApiIntegrationTest
683686
Original file line number Diff line number Diff line change 3434import org .springframework .ai .ollama .api .OllamaApi ;
3535import org .springframework .ai .ollama .api .OllamaChatOptions ;
3636
37- // @Disabled("To avoid making the assumption that Ollama is available in the CI pipeline")
38- @ EnabledIfEnvironmentVariable (named = "ADK_RUN_INTEGRATION_TESTS " , matches = "true" )
37+ /** Needs Docker for Ollama; runs only when {@code ADK_RUN_LOCAL_MODEL_TESTS=true}. */
38+ @ EnabledIfEnvironmentVariable (named = "ADK_RUN_LOCAL_MODEL_TESTS " , matches = "true" )
3939class LocalModelIntegrationTest {
4040
4141 private static OllamaTestContainer ollamaContainer ;
You can’t perform that action at this time.
0 commit comments