Signed-off-by: Andrey Berezin <a.berezin@yadro.com>
This commit is contained in:
Andrey Berezin 2024-02-05 18:49:45 +03:00 committed by Andrey Berezin
parent c978f55e90
commit b464591153
2 changed files with 15 additions and 0 deletions

View file

@ -147,6 +147,8 @@ class Preset:
pregen_json: Optional[str] = metadata_field(all_load_scenarios, "out", "PREGEN_JSON", False) pregen_json: Optional[str] = metadata_field(all_load_scenarios, "out", "PREGEN_JSON", False)
# Workers count for preset # Workers count for preset
workers: Optional[int] = metadata_field(all_load_scenarios, "workers", None, False) workers: Optional[int] = metadata_field(all_load_scenarios, "workers", None, False)
# Acl for container/buckets
acl: Optional[str] = metadata_field(all_load_scenarios, "acl", None, False)
# ------ GRPC ------ # ------ GRPC ------
# Amount of containers which should be created # Amount of containers which should be created

View file

@ -136,6 +136,7 @@ class TestLoadConfig:
def test_argument_parsing_for_grpc_scenario(self, load_params: LoadParams): def test_argument_parsing_for_grpc_scenario(self, load_params: LoadParams):
expected_preset_args = [ expected_preset_args = [
"--size '11'", "--size '11'",
"--acl 'acl'",
"--preload_obj '13'", "--preload_obj '13'",
"--out 'pregen_json'", "--out 'pregen_json'",
"--workers '7'", "--workers '7'",
@ -174,6 +175,7 @@ class TestLoadConfig:
"--ignore-errors", "--ignore-errors",
"--sleep '19'", "--sleep '19'",
"--local", "--local",
"--acl 'acl'",
] ]
expected_env_vars = { expected_env_vars = {
"DURATION": 9, "DURATION": 9,
@ -211,6 +213,7 @@ class TestLoadConfig:
"--location 's3_location'", "--location 's3_location'",
"--ignore-errors", "--ignore-errors",
"--sleep '19'", "--sleep '19'",
"--acl 'acl'",
] ]
expected_env_vars = { expected_env_vars = {
"DURATION": 9, "DURATION": 9,
@ -242,6 +245,7 @@ class TestLoadConfig:
"--location 's3_location'", "--location 's3_location'",
"--ignore-errors", "--ignore-errors",
"--sleep '19'", "--sleep '19'",
"--acl 'acl'",
] ]
expected_env_vars = { expected_env_vars = {
"DURATION": 183900, "DURATION": 183900,
@ -279,6 +283,7 @@ class TestLoadConfig:
"--location 's3_location'", "--location 's3_location'",
"--ignore-errors", "--ignore-errors",
"--sleep '19'", "--sleep '19'",
"--acl 'acl'",
] ]
expected_env_vars = { expected_env_vars = {
"DURATION": 9, "DURATION": 9,
@ -317,6 +322,7 @@ class TestLoadConfig:
"--policy 'container_placement_policy'", "--policy 'container_placement_policy'",
"--ignore-errors", "--ignore-errors",
"--sleep '19'", "--sleep '19'",
"--acl 'acl'",
] ]
expected_env_vars = { expected_env_vars = {
"DURATION": 9, "DURATION": 9,
@ -347,6 +353,7 @@ class TestLoadConfig:
"--policy 'container_placement_policy'", "--policy 'container_placement_policy'",
"--ignore-errors", "--ignore-errors",
"--sleep '19'", "--sleep '19'",
"--acl 'acl'",
] ]
expected_env_vars = { expected_env_vars = {
"CONFIG_FILE": "config_file", "CONFIG_FILE": "config_file",
@ -399,6 +406,7 @@ class TestLoadConfig:
"--containers '0'", "--containers '0'",
"--policy ''", "--policy ''",
"--sleep '0'", "--sleep '0'",
"--acl ''",
] ]
expected_env_vars = { expected_env_vars = {
"DURATION": 0, "DURATION": 0,
@ -427,6 +435,7 @@ class TestLoadConfig:
"--containers '0'", "--containers '0'",
"--policy ''", "--policy ''",
"--sleep '0'", "--sleep '0'",
"--acl ''",
] ]
expected_env_vars = { expected_env_vars = {
"DURATION": 0, "DURATION": 0,
@ -462,6 +471,7 @@ class TestLoadConfig:
"--buckets '0'", "--buckets '0'",
"--location ''", "--location ''",
"--sleep '0'", "--sleep '0'",
"--acl ''",
] ]
expected_env_vars = { expected_env_vars = {
"DURATION": 0, "DURATION": 0,
@ -490,6 +500,7 @@ class TestLoadConfig:
"--buckets '0'", "--buckets '0'",
"--location ''", "--location ''",
"--sleep '0'", "--sleep '0'",
"--acl ''",
] ]
expected_env_vars = { expected_env_vars = {
"DURATION": 0, "DURATION": 0,
@ -525,6 +536,7 @@ class TestLoadConfig:
"--containers '0'", "--containers '0'",
"--policy ''", "--policy ''",
"--sleep '0'", "--sleep '0'",
"--acl ''",
] ]
expected_env_vars = { expected_env_vars = {
"DURATION": 0, "DURATION": 0,
@ -553,6 +565,7 @@ class TestLoadConfig:
"--containers '0'", "--containers '0'",
"--policy ''", "--policy ''",
"--sleep '0'", "--sleep '0'",
"--acl ''",
] ]
expected_env_vars = { expected_env_vars = {
"CONFIG_FILE": "", "CONFIG_FILE": "",