Provide ChatGLM support for "generate test"
Related Issue:
- https://jihulab.com/gitlab-cn/gitlab/-/issues/3101
- https://jihulab.com/gitlab-cn/gitlab/-/issues/3010
What does this MR do and why?
Integrate ChatGLM to support generate_test_file
feature.
Take the test file generated by AI as an example, replace OpenAI with ChatGLM.
Screenshots or screen recordings
OpenAI | ChatGLM |
---|---|
How to set up and validate locally
Setup group:
project = Project.find(23)
namespace = project.root_ancestor
namespace.update!(experiment_features_enabled: true, third_party_ai_features_enabled: true)
namespace.gitlab_subscription.update!(plan_code: 'ultimate', trial: false, end_date: nil, seats: 100)
Setup ChatGLM Token:
export CHAT_GLM_API_KEY="<API-KEY>"
- Simulate a SaaS instance
- Feature.enable(:openai_experimentation)
- Feature.enable(:ai_related_settings, namespace)
- Feature.enable(:generate_test_file_flag, user)
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
由 Baodong 编辑于