mirror of
https://github.com/openai/codex.git
synced 2026-11-19 22:30:42 +00:00
Support Edu Plus and Edu Pro account plans (#39316)
## What changed - Recognize `edu_plus` and `edu_pro` as distinct education workspace plans across authentication, backend rate-limit mapping, and app-server account schemas. - Include both plans in cloud configuration eligibility and use the education usage-limit behavior. - Display the plans as `Edu Plus` and `Edu Pro` in the TUI status view. ## Testing - Cover parsing, workspace classification, account and rate-limit responses, cloud configuration eligibility, usage-limit messages, and TUI display names for the new variants. GitOrigin-RevId: bf8add780ae03a3c6d10c4f4afa0da262c37928e
This commit is contained in:
committed by
copyberry
parent
8ae72a9314
commit
657bd889ae
@@ -406,17 +406,24 @@ fn usage_limit_reached_error_formats_enterprise_cbp_usage_based_plan() {
|
||||
|
||||
#[test]
|
||||
fn usage_limit_reached_error_formats_default_for_other_plans() {
|
||||
let err = UsageLimitReachedError {
|
||||
plan_type: Some(PlanType::Known(KnownPlan::Enterprise)),
|
||||
resets_at: None,
|
||||
rate_limits: Some(Box::new(rate_limit_snapshot())),
|
||||
promo_message: None,
|
||||
rate_limit_reached_type: None,
|
||||
};
|
||||
assert_eq!(
|
||||
err.to_string(),
|
||||
"You've hit your usage limit. Try again later."
|
||||
);
|
||||
for plan in [
|
||||
KnownPlan::Enterprise,
|
||||
KnownPlan::Edu,
|
||||
KnownPlan::EduPlus,
|
||||
KnownPlan::EduPro,
|
||||
] {
|
||||
let err = UsageLimitReachedError {
|
||||
plan_type: Some(PlanType::Known(plan)),
|
||||
resets_at: None,
|
||||
rate_limits: Some(Box::new(rate_limit_snapshot())),
|
||||
promo_message: None,
|
||||
rate_limit_reached_type: None,
|
||||
};
|
||||
assert_eq!(
|
||||
err.to_string(),
|
||||
"You've hit your usage limit. Try again later."
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
||||
Reference in New Issue
Block a user