config: resolution reads the declarations, not the fields (#36253)
This commit is contained in:
@@ -7,6 +7,7 @@ translates field annotations into argparse arguments.
|
||||
import argparse
|
||||
import unittest
|
||||
|
||||
from sglang.srt.arg_groups.overrides import resolution_result
|
||||
from sglang.srt.server_args import ServerArgs
|
||||
from sglang.srt.utils.common import configure_media_url_security
|
||||
from sglang.test.ci.ci_register import register_cpu_ci
|
||||
@@ -95,8 +96,10 @@ class TestServerArgsAnnotatedCli(CustomTestCase):
|
||||
"32",
|
||||
]
|
||||
)
|
||||
# The normalization is a declaration.
|
||||
self.assertEqual(
|
||||
sa.allowed_media_domains, ["127.0.0.1", "media.example.com"]
|
||||
resolution_result(sa, "allowed_media_domains"),
|
||||
["127.0.0.1", "media.example.com"],
|
||||
)
|
||||
self.assertEqual(sa.media_url_max_file_size_mb, 32)
|
||||
finally:
|
||||
|
||||
Reference in New Issue
Block a user